add includedir entry to sudoers if its not there
This commit is contained in:
parent
55c9d3f13d
commit
4bec581e4e
3
stack.sh
3
stack.sh
@ -61,6 +61,9 @@ if [[ $EUID -eq 0 ]]; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
echo "Giving stack user passwordless sudo priviledges"
|
echo "Giving stack user passwordless sudo priviledges"
|
||||||
|
# natty uec images sudoers does not have a '#includedir'. add one.
|
||||||
|
grep -q "^#includedir.*/etc/sudoers.d" /etc/sudoers ||
|
||||||
|
echo "#includedir /etc/sudoers.d" >> /etc/sudoers
|
||||||
( umask 226 && echo "stack ALL=(ALL) NOPASSWD:ALL" \
|
( umask 226 && echo "stack ALL=(ALL) NOPASSWD:ALL" \
|
||||||
> /etc/sudoers.d/50_stack_sh )
|
> /etc/sudoers.d/50_stack_sh )
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user