forked from potsda.mn/mobilizon
Fix some dev config
Signed-off-by: Thomas Citharel <tcit@tcit.fr>
This commit is contained in:
parent
f68cbb18b0
commit
e0acff267b
1
.gitignore
vendored
1
.gitignore
vendored
|
@ -14,6 +14,7 @@ erl_crash.dump
|
||||||
# secrets files as long as you replace their contents by environment
|
# secrets files as long as you replace their contents by environment
|
||||||
# variables.
|
# variables.
|
||||||
/config/*.secret.exs
|
/config/*.secret.exs
|
||||||
|
/config/runtime.exs
|
||||||
|
|
||||||
/setup_db.psql
|
/setup_db.psql
|
||||||
|
|
||||||
|
|
|
@ -97,20 +97,3 @@ config :mobilizon, :anonymous,
|
||||||
reports: [
|
reports: [
|
||||||
allowed: true
|
allowed: true
|
||||||
]
|
]
|
||||||
|
|
||||||
require Logger
|
|
||||||
|
|
||||||
cond do
|
|
||||||
System.get_env("INSTANCE_CONFIG") &&
|
|
||||||
File.exists?("./config/#{System.get_env("INSTANCE_CONFIG")}") ->
|
|
||||||
import_config System.get_env("INSTANCE_CONFIG")
|
|
||||||
|
|
||||||
System.get_env("DOCKER", "false") == "false" && File.exists?("./config/dev.secret.exs") ->
|
|
||||||
import_config "dev.secret.exs"
|
|
||||||
|
|
||||||
System.get_env("DOCKER", "false") == "true" ->
|
|
||||||
Logger.info("Using environment configuration for Docker")
|
|
||||||
|
|
||||||
true ->
|
|
||||||
Logger.error("No configuration file found")
|
|
||||||
end
|
|
||||||
|
|
Loading…
Reference in a new issue