Trellis - No such file or directory on Deploy

Hello, I am having an issue with deployment. I have followed all of the steps in the example project (https://github.com/roots/roots-example-project.com) and was able to successfully set up my local dev environment. I was also able to provision the server with the following: ansible-playbook -i hosts/staging server.yml

However, when I try to deploy to DigitalOcean using ./deploy.sh staging amigoslink.org, I continuously get the following error:

TASK: [deploy | Create shared symlinks] ***************************************
failed: [45.55.89.50] => (item={‘path’: ‘web/app/uploads’, ‘src’: ‘uploads’}) => {“failed”: true, “item”: {“path”: “web/app/uploads”, “src”: “uploads”}, “path”: “/srv/www/amigoslink.org/releases/20150616135757/web/app/uploads”, “state”: “absent”}
msg: Error while linking: [Errno 2] No such file or directory

FATAL: all hosts have already failed – aborting

My DigitalOcean droplet was just created before this new attempt – Installed Ubuntu 14.0.4 and nothing else. Any Idea what might be causing this?

Here’s a video of that process if it helps: https://www.youtube.com/watch?v=6dc_epCn4Jk

There appears to be no “web” folder inside of this release folder:

That should have been created for me correct?

I’m guessing that this should be looking inside of the “site” folder? and not the “releases” folder?

Correct.

1 Like

@Swalkinshaw Worked! Thanks.

1 Like

I’ve been at this for a week now, spending most of my days trying to get this thing to work and I still can’t get it working on a fresh Digital Ocean Droplet. I’ve followed the example project exactly, and every other guide I’ve found. The closest I’ve been is this issue right here.

I’ve tried:

subtree: site
subtree_path: site
local_path: '../site'
local_path: ../site
wp_siteurl: http://bohemiancode.com/wp
wp_siteurl: http://bohemiancode.com

None of them seem to rid me of:

TASK: [deploy | Create shared symlinks] *************************************** 
failed: [128.199.135.3] => (item={'path': 'web/app/uploads', 'src': 'uploads'}) => {"failed": true, "item": {"path": "web/app/uploads", "src": "uploads"}, "path": "/srv/www/bohemiancode.com/releases/20150926175533/web/app/uploads", "state": "absent"}
msg: Error while linking: [Errno 2] No such file or directory

I’m running the latest versions of Trellis, Bedrock and Sage as I’ve freshly cloned them all this week. I will try again, but man I feel like 98% of being a web dev is spending time doing stuff like this which is meant to save me time… haha

It’s telling you there is no uploads folder… Have you added that yet?

I got it working by scratching the entire project, cloning the actual example project and changing the settings to match my server and database. It worked flawlessly but I can see that the process is somewhat different. I don’t remember exactly how different as I was doing all of this until 5.30am this morning.
Now that you mention it, perhaps I created an upload folder in the wrong place, to double check, it should be made so that it exists in:
/srv/www/example.com/shared/uploads
is that correct?

Yes that’s correct

20 chars

Thanks very much, I will try again from scratch when I get time during the week! I really appreciate your help :smile: