Bedrock on Dreamhost Shared hosting

Hey,

Just wondering if anyone has managed to deploy via capistrano to Dreamhost shared hosting?

I’ve been trying myself and have got as far as successfully configuring Cap, uploading the files to the server under it’s ‘releases’ folder. Where it fails is trying to run composer on the server. I’m wondering if this is a config error or something I’ve overlooked, or if it just plain doesn’t work on Dreamhost.

I have shell access, and I’ve added the line to enable composer in a PHP folder.

Regards,
Dave

Hey Dave,

I’m working towards a similar attempt but on Bluehost. I know Bedrock wasn’t meant for this type of environment but before I get embroiled in setting up a Digital Ocean droplet I want to try a full Capistrano deploy workflow to see whether it’s something I want to stick with.

You do need to have Composer installed on your server so that your dependencies get installed. I managed to successfully install it on Bluehost from this quick article.

Let me know how it goes!

This ended up lighting a fire under me to finally get Bedrock up and running on my current shared host (Bluehost). I succeeded after encountering a few issues and decided to write a blog post for anyone else interested in learning how to deploy WordPress with Capistrano on a shared host.

4 Likes

Just one minor note for deploy_to:

set :deploy_to, "/home2/whatever/public_html/#{fetch(:application)}"
# should be
set :deploy_to, -> { "/home2/whatever/public_html/#{fetch(:application)}" }

Obviously even more confusing to non Ruby people, but -> is a lambda function (basically anonymous function) which will get evaluated at run time to ensure that application is set. Not exactly sure under what conditions this could fail, but it’s safer.

Good to know and will definitely update that section… does Bedrock need to be updated to reflect this?

And of course it does… just updated it.

Haha, I wasn’t hounding you, just thought that might be specific to shared hosts for some weird reason. Thanks!