|
Re: cap 2 - cap deploy:setup not using sudo?: msg#00108lang.ruby.capistrano.general
Just dug into the code. setup uses 'run' instead of 'invoke_command'. After looking through the other deploy tasks, most things don't use invoke command. I suppose I'll just change the 'deploy_to' location for now, but wouldn't it make sense that you'd want to deploy the app into a system level location that would require sudo rights and chmod it so the user has access? Alex On Nov 16, 1:26 pm, Alex Soto <aps...-Re5JQEeQqe8AvxtiuMwx3w@xxxxxxxxxxxxxxxx> wrote: > Hey there, > > I'm setting up cap for the first time. I'm doing it against a server > I control. When I run cap deploy:setup I see it attempting the > commands but it's failing due to permissions. It doesn't seem to use > sudo. > > * I have the user setup in sudoers with NOPASSWD > * I've set the following in deploy.rb > default_run_options[:pty] = true (suggestion from another post, > but likely a cap 1.0 solution) > set :use_sudo, true (even though it should default to true) > > This is the output: (snipped a little bit) > * executing `deploy:setup' > * executing "umask 02 && mkdir -p /var/www/myapp /var/www/myapp/ > releases /var/www/myapp/shared /var/www/myapp/shared/system /var/www/ > myapp/shared/log /var/www/myapp/shared/pids" > servers: ["pref"] > [pref] executing command > ** [out :: pref] mkdir: cannot create directory `/var/www/myapp': > Permission denied > ** [out :: pref] mkdir: cannot create directory `/var/www/myapp': > Permission denied > ** [out :: pref] mkdir: cannot create directory `/var/www/myapp': > Permission denied > ** [out :: pref] mkdir: cannot create directory `/var/www/myapp': > Permission denied > ** [out :: pref] mkdir: cannot create directory `/var/www/myapp': > Permission denied > ** [out :: pref] mkdir: cannot create directory `/var/www/myapp': > Permission denied > command finished > command "umask 02 && mkdir -p /var/www/myapp /var/www/myapp/releases / > var/www/myapp/shared /var/www/myapp/shared/system /var/www/myapp/ > shared/log /var/www/myapp/shared/pids" failed on pref > > Thanks for any help, > > Alex |
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | cap 2 - cap deploy:setup not using sudo?: 00108, Alex Soto |
|---|---|
| Next by Date: | Re: Cap 2.1, Mac OS and ssh-askpass?: 00108, alertphil-Re5JQEeQqe8AvxtiuMwx3w@xxxxxxxxxxxxxxxx |
| Previous by Thread: | cap 2 - cap deploy:setup not using sudo?i: 00108, Alex Soto |
| Next by Thread: | Re: cap 2 - cap deploy:setup not using sudo?: 00108, Jamis Buck |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
| News | FAQ | advertise |