views:

109

answers:

1

So I want to be able to cap:deploy without having to type any passwords. I have setup all private keys so I can get to the remote servers fine, and am now using svn over ssh, so no passwords there.

I have one last problem, I need to be able to restart nginx. Right now I have sudo /etc/init.d/nginx reload. That is a problem b/c it uses the capistrano password, the one I just removed b/c I am using keys. Any ideas on how to restart nginx w\out a password?

A: 

You can setup sudo to not require a password. Edit your sudoers file (with visudo) and add a line like this:

username ALL=NOPASSWD: ALL

There are other options, for example, only allowing you to issue particular commands without the password, etc. More information is here and of course the sudoer man page

bramp