Skip to content

Commit

Permalink
Merge pull request #65 from jlm3575/jlm3575/remove-upstart-sudo
Browse files Browse the repository at this point in the history
Removing sudo from upstart script.
  • Loading branch information
ernestas-poskus authored May 18, 2017
2 parents 45d1113 + 0d958ee commit 1f27c7d
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion templates/zookeeper.conf.j2
Original file line number Diff line number Diff line change
Expand Up @@ -13,5 +13,7 @@ umask 007
kill timeout 300

script
exec sudo -u zookeeper -g zookeeper {{zookeeper_dir}}/bin/zkServer.sh start-foreground > /var/log/zookeeper/init-zookeeper.log 2>&1
# https://superuser.com/questions/213416/running-upstart-jobs-as-unprivileged-users
exec su -s /bin/sh -c 'exec "$0" "$@" &>>/var/log/zookeeper/init-zookeeper.log' zookeeper -- \
{{zookeeper_dir}}/bin/zkServer.sh start-foreground
end script

0 comments on commit 1f27c7d

Please sign in to comment.