Skip to content

Commit

Permalink
fixup: fix crowding app config
Browse files Browse the repository at this point in the history
  • Loading branch information
rudiejd committed Feb 3, 2025
1 parent d3f8986 commit fcd0e13
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
4 changes: 3 additions & 1 deletion apps/state_mediator/config/config.exs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,9 @@ config :state_mediator, :commuter_rail_crowding,
"https://keolis-api-development.firebaseio.com/p-kcs-trms-firebase-7dayloading.json"
},
enabled: {:system, "CR_CROWDING_ENABLED", "true"},
source: :s3
s3_bucket: {:system, "CR_CROWDING_S3_BUCKET"},
s3_object: {:system, "CR_CROWDING_S3_OBJECT"},
source: {:system, "CR_CROWING_SOURCE", "s3"}

config :state_mediator, Realtime,
gtfs_url: {:system, "MBTA_GTFS_URL", "https://cdn.mbta.com/MBTA_GTFS.zip"},
Expand Down
2 changes: 1 addition & 1 deletion apps/state_mediator/lib/state_mediator.ex
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ defmodule StateMediator do
children(Application.get_env(:state_mediator, :start)) ++
crowding_children(
app_value(:commuter_rail_crowding, :enabled) == "true",
app_value(:commuter_rail_crowding, :source)
app_value(:commuter_rail_crowding, :source) |> :erlang.binary_to_atom()
)

# See http://elixir-lang.org/docs/stable/elixir/Supervisor.html
Expand Down
2 changes: 1 addition & 1 deletion config/runtime.exs
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ if is_prod? and is_release? do
config :state_mediator, :commuter_rail_crowding,
s3_bucket: System.fetch_env!("CR_CROWDING_S3_BUCKET"),
s3_object: System.fetch_env!("CR_CROWDING_S3_OBJECT"),
source: :s3
source: System.fetch_env!("CR_CROWDING_SOURCE")

config :recaptcha,
enabled: true,
Expand Down

0 comments on commit fcd0e13

Please sign in to comment.