Docker file for Trellis + Bedrock + Sage?


#21

@ssteinerX i could not find your email, so i type here. I’m very interested in Docker + Bedrock, could you please share your Docker configurations with me? My email is me@hmphu.com


#22

I’ve built a neat development setup for Bedrock with docker over here: https://github.com/schliflo/bedrock-docker
Would love to get some feedback - so if you happen to have some time: try it and drop me a line if you like it or not. I’m happy to assist if you run into any problems.


#23

@schliflo Any tips on where to look to deploy bedrock-docker? Say on AWS in particular?


#24

Am I on the right track with this overall idea:

  • containers for DB, shared files, unaffected by deploys
  • container for app, hosting wp and the themes
  • deploys build a new app container from project repo, swaps current container with new one

But what about compiling front-end assets and other sage tasks trellis automates when running the deploy ansible script? Anybody got a suggestion on that end?


#25

https://github.com/schliflo/bedrock-docker is not intended for production use! This is only a local development setup. Actually deploying this to production will result in Wordpress never sending emails to your users as the app container is configured to use mailhog.
I thought about building production containers and deployment routines but I could not think of a valid use case as I personally think that running docker containers in production is not worth the effort unless you need to scale your service to thousands of concurrent users - at which point you’re probably building your own containers anyways.
Personally I deploy my stuff using Gitlab CI Pipelines - they are great for building Frontend assets, installing composer dependencies etc… So maybe thats worth a look :wink:


#26

Would also like to see if the community would prefer a Docker setup over Trellis. Shipping a single container across server seems like a much better idea than having to provision each server individually.

Docker would be easier to scale & is more simple to use.