Roots Discourse

Deploying WordPress with Capistrano screencast


#62

Is everything working now?


#63

Yes, finally! Just when I was at the very brink, my laptop decided to co-operate! I have even moved to mariadb for testing and because this little laptop can’t handle running a vbox alongside phpstorm (I have already reduced its max ram usage to under 300mb) I am using brewstack. It will have to do for now!
I am managing all my database with SequelPro, goodbye phpmyadmin forever!

I will keep you posted on any issues if I run into them!


#64

Thanks for the awesome screencast! When deploying a site that uses composer to manage wordpress and plugins, would there be any issues adding the vendor dir to the linked dirs?


#65

That’s a common question and the best discussion I’ve had about this is on my npm Capistrano gem (same concept applies): https://github.com/capistrano/npm/issues/7


#66

I am probably out of place stating this here, but i think the screencast needs to be updated as on current Mac’s OSX the new System Integrity Protection prevents you from installing gems called/that are rootless.

You get the error message

ERROR:  While executing gem ... (Errno::EPERM)

so to install Bundle one has to:

sudo gem install -n /usr/local/bin GEM_NAME_HERE

which then throws up all sorts of issues when trying to run bundle commands such as

Could not locate Gemfile or .bundle/ directory

so at this point in time i am stuck about 11 minutes into the screencast!!


#67

I’ll have to go back and watch the screencast again to see how I talk about installing gems, but yeah sudo shouldn’t be used here. The way around it is to just use bundle without it.

See https://gorails.com/setup/osx/10.12-sierra for instructions on using rbenv to install Ruby. It’s more work but guarantees no issues with sudo or permissions.

edit: ignore the rest about Rails. Just the part about rbenv + bundler itself.