EC2 deployment strategy

Is there a step-by-step procedure / explanation that exists somewhere for deploying on an EC2 instance with Trellis?

I’m trying to figure out what needs to be done, every step of the way, to make it near as easy as it is on DO. Reading a few topics here led me to 2 different approaches that could be tackled.

1- Configuring / Changing things in Trellis to accommodate the way that EC2 instances are built out the box. (I.E : default admin user is Ubuntu, can’t really log in as root without the key pair file, etc.)

2- Setting up the EC2 instance the closest we possibly can to a default DO droplet (create proper users and access rights, authenticate with the same ssh key used by DO, etc)

If any of this is wrong, please correct me.

It looks like some people here we able to do it but everyone had their different issues and I’m missing some pieces.

If there is no complete procedure that exists right now, I am willing to put something together with the results of this discussion as soon as I will figure it out.


I’ve only spun up a few basic EC2 instances for testing. The only difference from DO that I remember is that you’ll need to change to admin_user: ubuntu.

Otherwise, I think the Trellis README and docs are your step by step explanation. Like DO, you’ll want to use the AWS UI to assign the instance your public SSH key, power up the instance, add its public IP to hosts, then run the server.yml and deploy.yml playbooks.

I’d suggest giving it a shot, searching the docs and discourse if you run into trouble. If you encounter issues you’re unable to resolve, create narrow/targeted discourse threads. Enjoy.


I will be deploying on EC2 myself imminently and I bookmarked some multiple notes from another thread that seems to indicate the whole package includes 1) using admin_user: ubuntu, 2) [adding PEM to keychain] ( (if on a Mac), 3) Adding EC2 hostname to /etc/hosts/ for SSMTP to work, and 4) switching from AWS pem key to your rsa key.

@jolaurin, I am really curious what your findings may be when you get it working.