Skip to content

Commit

Permalink
Merge pull request #4 from linuxserver/aptalca-patch-1
Browse files Browse the repository at this point in the history
fix if grep
  • Loading branch information
CHBMB authored Jul 9, 2019
2 parents 97181b1 + 88d09c9 commit 43281e3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion root/etc/cont-init.d/30-config
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ mkdir -p /config/{extensions,data,workspace,.ssh}

if [ -n "${SUDO_PASSWORD}" ]; then
echo "setting up sudo access"
if [ ! $(cat /etc/sudoers | grep abc) ]; then
if [ ! $(grep -c 'abc' /etc/sudoers) ]; then
echo "adding abc to sudoers"
echo "abc ALL=(ALL:ALL) ALL" >> /etc/sudoers
fi
Expand Down

0 comments on commit 43281e3

Please sign in to comment.