JovaniPink
I just saw the announce of Awesome-Compose, “a Github repository with application samples” using Docker Compose.
Announcement Blog:
Awesome Compose for Sample Apps
Actual Git Repo:
Awesome-Compose
I thought it would be a great community effort if we added solid, regularly used, and popular docker compose recipes to the list.
Could you’all send me links or guides me to any examples that the community uses so we could add.
Thank you and for your support!
PS: I’m just starting off with Elixir and Phoenix and this would be super beneficial for me. ![]()
Trending in Discussions
As the title says, please share what you’ve been up to with Elixir. Whether that’s been learning it, looking into it, making stuff with i...
New
The obligatory hello world thread!
Who are you and where are you from? :stuck_out_tongue:
New
I want to open this thread for you all to discuss and help those who really like Ash but are still hesitant to use it in a real project. ...
New
I was working on an Ecto migration and I needed a timestamp. So, for the nth time, I looked up the different data types for timestamps, a...
New
Fly’s CEO posted this recently - Turn And Face The Strange · The Fly Blog
It says that Fly is going all-in on sprites, which is a worry ...
New
We’re evaluating API mocking tools for OpenAPI-based projects and would love to hear what other teams are using.
We’re particularly inte...
New
Is there a word for the ~> symbol used in Version strings?
Do you also just call it a Squiggle Arrow™ ?!
New
Other Trending Topics
Hobbes is a low-level distributed database for the Elixir programming language.
Hobbes provides a simple, safe, and scalable storage lay...
New
Beam Bots (or just BB for short) is a framework for building fault-tolerant robotics applications in Elixir using familiar OTP patterns. ...
New
ExRatatui lets you cook up rich terminal UIs in Elixir, powered by Rust’s ratatui via Rustler NIFs. Build interactive terminal applicatio...
New
Hello everyone. After busy few months I am happy to announce v0.1.0 of Emerge & Solve.
They are GUI (Emerge) and State management (S...
New
Corex is an accessible, unstyled UI component library for Phoenix that integrates Zag.js state machines using Vanilla JavaScript and Live...
New
There are three potential reasons for members of this forum to have a look at https://vutuv.de
You are tired or annoyed of LinkedIn.
Yo...
New
Latest Phoenix Threads
Latest on Elixir Forum
Categories:
Sub Categories:
Forums
Popular Tags
- #ecto
- #liveview
- #troubleshooting
- #learning-elixir
- #deployment
- #library
- #erlang
- #testing
- #genserver
- #mix
- #absinthe
- #remote-other
- #otp
- #plug
- #how-to-question
- #macros
- #postgres
- #channels
- #elixirconf
- #exunit
- #discussion
- #code-sync
- #javascript
- #podcasts
- #onsite
- #dialyzer
- #docker
- #authentication
- #umbrella
- #full-time-contract
- #podcasts-by-brainlid
- #ecto-query
- #elixir-ls
- #blog-post
- #ai
- #phoenix_html
- #iex
- #elixirconf-us
- #graphql
- #genstage
- #websockets
- #supervisor
- #advent-of-code
- #distillery
- #processes
- #api
- #forms
- #hex
- #security
- #metaprogramming











Showing Posts 1 to 10- Show Best Posts
- Show All (oldest first)
- Show All (newest first)
gregvaughn
In contrast I am quite comfortable with Elixir and Phoenix but I’m a novice at Docker. My main impression comes from all the people having problems with it. Knowing that solid recipes exist would be a huge benefit.
nayibor
above is a compose file i used for an erlang web application
so the compose file had sections for
erlang -for the web application(one port for application and one for edoc html files)
mysql -for the database
rabbitmq - for rabbitmq server
node - was using zurb framework for frontend so needed a nodejs image
swagger -for the api editor
below is also a simpler one for elixir which i have used before
JovaniPink
Thank you sharing.
kous
I have opened a PR Sample for phoenix(elixir)-postgres by ekousanakis · Pull Request #55 · docker/awesome-compose · GitHub , your comments are more than welcome!
JovaniPink
Great work and thank you for taking the initiative. I found a couple of Elixir-Phoenix-Postgres docker-compose out in the wild … https://github.com/nicbet/docker-phoenix, https://binarynoggin.com/deploying-phoenix-with-circleci/, and of what @nayibor added up top and to your pull request.
I appreciate it.
axelclark
I have a docker-compose.yml file in a blog post I wrote:
https://axelclark.com/deploy-phoenix-to-digital-ocean/#build-release-with-docker
JackMaarek
I have one docker-compose.yml file that build the phoenix container for backend and a elm app container for front-end:
You can access the repo here : GitHub - HETIC-MT-P2021/aio-group3-proj01: Elm application with Phoenix API on Docker : Edwin Vautier - Jack Maarek - Jason Gauvin · GitHub
Here is the docker-compose.yml:
The Docker file for backend api:
with a setup shell file :
And the dockerfile for frontend:
JovaniPink
Sweet Work.
akoutmos
I leverage Docker Compose for most of my tutorials on my blog. Below is a listing of the tech stacks, articles, and repos for each of the tutorials:
Prometheus, PostGIS and Phoenix Part 1
Article: Prometheus, PostGIS and Phoenix Part 1-Alex Koutmos | Engineering Blog
Repo: GitHub - akoutmos/elixir_monitoring_prom: Companion code for https://akoutmos.com/post/prometheus-postgis-and-phoenix/ · GitHub
Tech Stack: Elixir app, Postgres+PostGIS, Grafana, Prometheus, Postgres Exporter
Broadway, RabbitMQ, and the Rise of Elixir Part 1
Article: Broadway, RabbitMQ, and the Rise of Elixir Part 1-Alex Koutmos | Engineering Blog
Repo: GitHub - akoutmos/elixir_popularity: Companion code for https://akoutmos.com/post/broadway-rabbitmq-and-the-rise-of-elixir/ · GitHub
Tech Stack: cAdvisor, RabbitMQ, Postgres, Postgres Exporter, Grafana, Prometheus
Structured logging in Elixir using Loki
Article: Structured logging in Elixir using Loki-Alex Koutmos | Engineering Blog
Repo: GitHub - akoutmos/auto_finder: Companion code for https://akoutmos.com/post/elixir-logging-loki/ · GitHub
Tech Stack: Elixir app, Postgres, Loki, Grafana
And finally, while not Docker Compose specific, how to build Mix Releases with Docker:
Multi-stage Docker Builds and Elixir 1.9 Releases
Article: Multi-stage Docker Builds and Elixir 1.9 Releases-Alex Koutmos | Engineering Blog
Repo: GitHub - akoutmos/docker_elixir_19_release: Companion code for https://akoutmos.com/post/multipart-docker-and-elixir-1.9-releases/ · GitHub
JackMaarek
Ok guys so I found that when you use volumes in docker-compose your create some side effects that could result in problems.
When you use the volume and pull everything from your project root directory you are overloading the content of the compiled stuff in your container so some dependencies won’t be “accessible” as their dependencies need to be compiled in order to work correctly.
Off course correct me if i’m wrong.
From my initial post I had a .docker folder that contains the necessary Dockerfile for my image with a setup shell script and in my project root directory I had my docker-compose file that was pulling all the project and target the project folder in my container.
Now I moved out my dockerfile in my project root directory because I canot copy files from a parent path of the context and even if it’s logic I do not really get how to keep my dockerfile in the docker folder, this is not much but I was usually using volumes in my compose files also to pull the source code even after a change. I’m also a little bit confused because this mean that at every change you need to rebuild the project, that’s a time waste.
At least you could only copy your mix.deps files and compile them but if you’re still using volumes you will override the deps and _build folder. For now I’m staying with this approach but do not hesitate to share your reviews !
The almighty @NobbZ explained very well all the side effects that this would cause and how a container should really behave: here.
Thanks a lot man !