1

I'm trying to allow my wheel group user to run sudo composer self-update without a prompt for a password for my deploy script.

I have added the bottom line below to my /etc/sudoers file:

## Allows people in group wheel to run all commands
%wheel  ALL=(ALL)       ALL
%wheel  ALL=(ALL)       NOPASSWD: /usr/local/bin/composer

But it is still prompting for a password.

Removing the next line up removed my ability to sudo any command as the user.

Have I done something wrong? Do I need to restart something?

Arth
  • 353
  • 5
  • 14

1 Answers1

0

Turns out it works if I run the command and specify the location exactly:

sudo /usr/local/bin/composer self-update
Arth
  • 353
  • 5
  • 14