joshfng/railsready — Issue #21: sudo check fails for users with passwordless sudo functionality
Author: jamiequint
Created: 2012-02-11 01:36:14+00:00
State: open

Default user on Ubuntu's official ec2 image is 'ubuntu' and ec2 requires this user has passwordless sudo functionality:

*From /etc/sudoers
# ubuntu user is default user in ec2-images.
# It needs passwordless sudo functionality.
ubuntu ALL=(ALL) NOPASSWD:ALL

However this user does not pass the sudo check in the railsready script:

*From railsready.sh
# Check if the user has sudo privileges.
sudo -v >/dev/null 2>&1 || { echo $script_runner has no sudo privileges ; exit 1; }