Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Something I don't understand in the documentation #15

Open
vauvarin opened this issue Apr 23, 2013 · 3 comments
Open

Something I don't understand in the documentation #15

vauvarin opened this issue Apr 23, 2013 · 3 comments

Comments

@vauvarin
Copy link

Hi Mark,

I try to install Capistrano and WP-Stack to use them for my WP Multisite deployment process.

There are some things I'm not sure to understand.

1- Why do we need to create a new user "deploy"?

2- In the doc. (Setup > 5. ) you wrote ...
Switch to the deploy user (su deploy) and check out WP Stack somewhere on your server: git clone [email protected]:markjaquith/WP-Stack.git ~/deploy

To be able to clone your repo. from Github on my PC, you have to accept my public key no? So I can't run your command above.

To clone your repo, I must enter this command instead
git clone git://github.com/markjaquith/WP-Stack.git

3- In the doc. (Setup > 7. ) you wrote ...
Make sure your :deploy_to path exists and is owned by the deploy user: chown -R deploy:deploy /path/to/your/deployment

Does it mean I must create the "deploy" user to my remote server before to run the command chown -R deploy:deploy /path/to/your/deployment ?

I am wrong? There is something I didn't understand?

@vauvarin
Copy link
Author

I think what I misunderstand is where to create the "deploy" user. I thought it was on my local system but I suppose I'm wrong, it should be on the remote server?

Someone could confirm?

@andrewscofield
Copy link

Yes on the remote server you would need to create the deploy user.

Also, if the git repo you are deploying is private you will have to have this deploy user generate keys on the server and add those to your github account so the server would have privileges needed to clone when you deploy.

@vauvarin
Copy link
Author

Thanks apotropaic for your answer. I created the user "deploy" on my remote server.

When I run "cap production deploy" everything is ok until the script ask me a password for deploy. As you know "deploy" user has no password due to "--disabled-password" in the Mark's "adduser" cmd

(see screenshot)
http://d.pr/i/bX51

Do I need to add the "deploy" user to the sudoers group?

This is how I tried to resolve my diffrent problems to run WP-Stack :

1 - Add this to my config.rb:

ssh_options[:forward_agent] = true
default_run_options[:pty] = true

2 - Replace "sudo" by "#{sudo}" in "/lib/tasks.rb" file

3 - Add "deploy" user to the sudo group on my remote server
sudo usermod -a -G sudo deploy

... The script steal asks me the password.
When I enter the sudo password, I've got the message "Sorry, try again".

Someone else had the same problem http://stackoverflow.com/questions/12420417/how-to-deploy-wordpress-with-capistrano-on-shared-host-without-sudo

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants