This one contains resources related to the deployment of Elixir apps using releases. It's a very basic approach but should be good as a start point.
Dockerfile
- multi-stage Dockerfile that produces super light image (app stage based on Alpine linux)config.exs
- config read on at build timeruntime.exs
- runtime configrelease.ex
- to run custom commands in production (e.g. migrations)
- functions defined in
release.ex
can be invoked viaeval
orrpc
commands (e.g../bin/my_app rpc MyApp.Release.migrate
) - use runtime config to configure app via environment variables
- use
System.fetch_env!
in runtime config to fail fast when some ENVs are missing