Bash script to automate setup

Hi there

I’m not sure if this is a good idea or not, but in my testing and fiddling I got fed up with copying and pasting commands to install Bedrock, Trellis and Sage, so I setup a shell script to automate this. Wondering if anyone else might find this useful, or if anyone has any feedback I’d love to hear it.

A few caveats:

  1. I’m pretty green with Trellis/Bedrock/Ansible, so I’d love to hear any feedback or critiques of the script and my methods.

  2. I’ve tried to keep this as generic as possible, but it is somewhat tailored to my needs - that said, there are no additional dependencies beyond what Bedrock/Trellis/Sage requires.

  3. This is a work in progress - I’m actually unsure of how much configuration should be automated via this script, but I’d love to keep it updated.



This is great. We’re all for automating things! The script itself looks fine although I’m not good enough with Bash to review it more in-depth.

Just a note that @austin has some plans to write a CLI tool to do what you’ve done and a little more. The goal is to make a kind of generator which will also serve to automatically keep our roots-example-project repo up to date.

Many thanks - so glad to be able to contribute something!

A CLI tool would be amazing - @austin If there’s a way to sign up for beta testing, I’d love to be involved.

Thanks again.

1 Like

Would love your thoughts over at

@tobyl thanks for the ground work on this script, I went through and slightly modified it but brought it up to speed with current repo hierarchy.

Can you let me know your thoughts, should I add anything else? will be giving credit in final version shortly.

Created it this so you can quickly deploy via a command:
$ trellis-setup project-name
This builds out the rest of the project, sets the staging name & url ""
Todo: check against /etc/hosts for matching ip’s and update ip address so it had unique octet