trying out more config changes to get this working

This commit is contained in:
2026-04-03 18:13:00 -04:00
parent 0aa3d269a3
commit bc71b0208a

View File

@@ -27,10 +27,10 @@ if config_env() == :prod do
config :mixer, Mixer.Repo, config :mixer, Mixer.Repo,
# ssl: true, # ssl: true,
username: System.get_env("DB_USER") || raise("Missing environment variable `DB_USER`!"), username: System.fetch_env!("DB_USER") || raise("Missing environment variable `DB_USER`!"),
password: System.get_env("DB_PASS") || raise("Missing environment variable `DB_PASS`!"), password: System.fetch_env!("DB_PASS") || raise("Missing environment variable `DB_PASS`!"),
host: System.get_env("DB_HOST") || raise("Missing environment variable `DB_HOST`!"), host: System.fetch_env!("DB_HOST") || raise("Missing environment variable `DB_HOST`!"),
database: System.get_env("DB_NAME") || raise("Missing environment variable `DB_NAME`!"), database: System.fetch_env!("DB_NAME") || raise("Missing environment variable `DB_NAME`!"),
port: String.to_integer(System.get_env("DB_PORT", "5432")), port: String.to_integer(System.get_env("DB_PORT", "5432")),
pool_size: String.to_integer(System.get_env("POOL_SIZE") || "10"), pool_size: String.to_integer(System.get_env("POOL_SIZE") || "10"),
# For machines with several cores, consider starting multiple pools of `pool_size` # For machines with several cores, consider starting multiple pools of `pool_size`
@@ -43,7 +43,7 @@ if config_env() == :prod do
# to check this value into version control, so we use an environment # to check this value into version control, so we use an environment
# variable instead. # variable instead.
secret_key_base = secret_key_base =
System.get_env("SECRET_KEY_BASE") || System.fetch_env!("SECRET_KEY_BASE") ||
raise """ raise """
environment variable SECRET_KEY_BASE is missing. environment variable SECRET_KEY_BASE is missing.
You can generate one by calling: mix phx.gen.secret You can generate one by calling: mix phx.gen.secret
@@ -66,38 +66,38 @@ if config_env() == :prod do
config :mixer, config :mixer,
token_signing_secret: token_signing_secret:
System.get_env("TOKEN_SIGNING_SECRET") || System.fetch_env!("TOKEN_SIGNING_SECRET") ||
raise("Missing environment variable `TOKEN_SIGNING_SECRET`!") raise("Missing environment variable `TOKEN_SIGNING_SECRET`!")
# Configure S3-compatible storage (MinIO/Garege/AWS S3) # Configure S3-compatible storage (MinIO/Garege/AWS S3)
config :ex_aws, config :ex_aws,
access_key_id: access_key_id:
System.get_env("S3_ACCESS_KEY_ID") || System.fetch_env!("S3_ACCESS_KEY_ID") ||
raise("Missing environment variable `S3_ACCESS_KEY_ID`!"), raise("Missing environment variable `S3_ACCESS_KEY_ID`!"),
secret_access_key: secret_access_key:
System.get_env("S3_SECRET_ACCESS_KEY") || System.fetch_env!("S3_SECRET_ACCESS_KEY") ||
raise("Missing environment variable `S3_SECRET_ACCESS_KEY`!") raise("Missing environment variable `S3_SECRET_ACCESS_KEY`!")
config :ex_aws, :s3, config :ex_aws, :s3,
scheme: System.get_env("S3_SCHEME", "https://"), scheme: System.get_env("S3_SCHEME", "https://"),
host: host:
System.get_env("S3_HOST") || System.fetch_env!("S3_HOST") ||
raise("Missing environment variable `S3_HOST`!"), raise("Missing environment variable `S3_HOST`!"),
port: String.to_integer(System.get_env("S3_PORT", "80")), port: String.to_integer(System.get_env("S3_PORT", "80")),
virtual_host: System.get_env("S3_VIRTUAL_HOST", "false") == "true" virtual_host: System.get_env("S3_VIRTUAL_HOST", "false") == "true"
config :waffle, config :waffle,
bucket: bucket:
System.get_env("S3_BUCKET") || System.fetch_env!("S3_BUCKET") ||
raise("Missing environment variable `S3_BUCKET`!"), raise("Missing environment variable `S3_BUCKET`!"),
asset_host: asset_host:
System.get_env("S3_ASSET_HOST") || System.fetch_env!("S3_ASSET_HOST") ||
raise("Missing environment variable `S3_ASSET_HOST`!") raise("Missing environment variable `S3_ASSET_HOST`!")
config :mixer, Mixer.Mailer, config :mixer, Mixer.Mailer,
adapter: Swoosh.Adapters.Brevo, adapter: Swoosh.Adapters.Brevo,
api_key: api_key:
System.get_env("BREVO_API_KEY") || System.fetch_env!("BREVO_API_KEY") ||
raise("Missing environment variable `BREVO_API_KEY`!") raise("Missing environment variable `BREVO_API_KEY`!")
# ## SSL Support # ## SSL Support