Setting up a staging environment in Elixir with Phoenix?

I am trying to set up an intermediate environment and run into problems compiling using anything other than prodfor my mix env. Ive tried setting up a custom env called stagwith a file stag.exsand all that, but it seems to have broken. I am sure that because of this line, I see in mix.exs:

build_embedded: Mix.env == :prod,
start_permanent: Mix.env == :prod,

The problem is that I see this line in all deps folders. Does this mean that I should use Mix.envfor prodeven for my intermediate environments?

+4
source share
1 answer

, . release , MIX_ENV -, prod. stag stag.exs, . , , :

IRC- Elixir, :prod , . , MIX_ENV=prod, prod.exs, , , , , prod.exs :

deployment_config=System.get_env("DEPLOYMENT_CONFIG")
import_config "./deployment_config/#{deployment_config}.exs"

, .

+11

Source: https://habr.com/ru/post/1650481/


All Articles