Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use Mix.env instead of setting up our own #292

Merged
merged 1 commit into from
Jan 13, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 0 additions & 3 deletions config/dev.exs
Original file line number Diff line number Diff line change
Expand Up @@ -74,9 +74,6 @@ config :dpul_collections, DpulCollectionsWeb.Endpoint,
]
]

# Set environment
config :dpul_collections, :current_env, :dev

config :dpul_collections, :basic_auth_username, "admin"
config :dpul_collections, :basic_auth_password, "admin"

Expand Down
3 changes: 0 additions & 3 deletions config/prod.exs
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,6 @@ import Config
config :dpul_collections, DpulCollectionsWeb.Endpoint,
cache_static_manifest: "priv/static/cache_manifest.json"

# Set environment
config :dpul_collections, :current_env, :prod

# Enable dev routes - including mailbox preview and the dashboard.
config :dpul_collections, dev_routes: true

Expand Down
3 changes: 0 additions & 3 deletions config/test.exs
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,6 @@ config :dpul_collections, DpulCollectionsWeb.Endpoint,
# In test we don't send emails.
config :dpul_collections, DpulCollections.Mailer, adapter: Swoosh.Adapters.Test

# Set environment
config :dpul_collections, :current_env, :test

# Set basic auth
config :dpul_collections, :basic_auth_username, "admin"
config :dpul_collections, :basic_auth_password, "test"
Expand Down
2 changes: 1 addition & 1 deletion lib/dpul_collections/application.ex
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ defmodule DpulCollections.Application do
# Start to serve requests, typically the last entry
DpulCollectionsWeb.Endpoint,
DpulCollections.IndexMetricsTracker
] ++ environment_children(Application.fetch_env!(:dpul_collections, :current_env))
] ++ environment_children(Mix.env())

# See https://hexdocs.pm/elixir/Supervisor.html
# for other strategies and supported options
Expand Down
Loading