aura
aura copied to clipboard
`nobody` can't build Rust/Java packages
I think this problem might be related to how aura separates build process from root and "my" user.
Failure that I have is related to a HOME directory of nobody that is set to / and missing rust default toolchain.
error: could not create home directory: '/.rustup'
How are you invoking the build? What's the exact command that you're running?
I'm experiencing the same issue with other Rust packages from AUR.
$ aura -Akxua
...
error: could not create home directory: '/.rustup': Permission denied (os error 13)
I think this problem might be related to how aura separates build process from root and "my" user. Failure that I have is related to a HOME directory of nobody that is set to
/and missing rust default toolchain.
If so, this seems to cause even more problems, e.g. with some other packages:
Verifying source file signatures with gpg...
dropbox-lnx.x86_64-205.4.5765.tar.gz ... SIGNATURE NOT FOUND
FAILED
==> ERROR: One or more PGP signatures could not be verified!
@mkoloberdin To confirm: you're running Aura as the root user and without invoking sudo manually, yeah?
I run aura with sudo, always. It does not work with root account - like after sudo -s or su.
Running aura with sudo is no longer necessary as of Aura 4. It should work as-is for root now as well. @CapSel , can you try rebuilding the original Rust package you were trying to build? Note that Aura is also a Rust package and can build itself without issue.
Omitting sudo for aura 4.0.3 also solved these issues for me when building the packages firefox-tridactyl-native and amdgpu-top with sudo aura -Aua:
oserrors.nim(92) raiseOSError
Error: Permission denied
... Additional info: /.nimble/
==> ERROR: A failure occurred in build().
Aborting...
aura :: Package failed to build, citing:
makepkg failed.
and
error: could not create home directory: '/.rustup': Permission denied (os error 13)
==> ERROR: A failure occurred in prepare().
Aborting...
aura :: Package failed to build, citing:
makepkg failed.
I assume users of aura are used to calling sudo aura ... from the time before the transition from Haskell to Rust. I appreciate that the new aura apparently doesn't need root permissions anymore.
I assume users of aura are used to calling sudo aura ... from the time before the transition from Haskell to Rust.
I posted that it's no longer necessary across every sensible doc location I can think of, but old habits are probably hard to break. At least these Issues will serve as a record for anyone else who runs into the same thing.
See also #873
Closing, as running Aura without sudo avoids the issue.
I've got similar problem with su instead of sudo when compiling sourcetrail:
[ERROR] Could not create local repository at /.m2/repository -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/LocalRepositoryNotAccessibleException
Same error with sudo.
Is it related?
What was the command you used to run Aura?
aura -Aux for upgrade, as I already had sourcetrail installed before.
And if it's trying to create /.m2/, I suppose you're running as the root user (thus dropping down to nobody)?
Same error happens when I this command as root and with sudo.
So as mentioned with ~/.cargo/ above, it seems that certain languages need temporary folders in which to put their dependencies during the build process, and by default they put them under ~/. When Aura is used as root, it drops down to nobody for building. However, nobody has no $HOME, so it attempts to write to / which it has no permission to do.