mirror of
https://github.com/dehydrated-io/dehydrated.git
synced 2026-01-11 22:30:44 +01:00
Remove dependency on sudo? #347
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @tovine on GitHub (May 16, 2018).
I noticed that dehydrated refuses to run without
sudoinstalled ifDEHYDRATED_USERis set - why is that?The same feature (restarting the script as a different user) is also perfectly doable using the
sucommand:su $DEHYDRATED_USER -s /bin/bash -c "${0} ${ORIGARGS}"; the only difference I can see immediately is the option to explicitly specify the group to run as.While
sudomay be more feature-complete in some respects,suis "guaranteed" to be present in mostly any system you would run on and IMO should at least be provided as a fallback ifsudois not found.I can probably make a PR for it if you want me to.
@lukas2511 commented on GitHub (May 22, 2018):
Using sudo does allow for a user switch without the need for a password (if configured). Also the group option might be needed by some people. Nobody forces you to use the dehydrated integrated sudo operation, you could always just use
suyourself.@Mischelle89 commented on GitHub (May 22, 2018):
go
Using sudo does allow for a user switch without the need for a password (if configured). Also the group option might be needed by some people. Nobody forces you to use the dehydrated integrated sudo operation, you could always just use su yourself.