Skip to content

Commit

Permalink
fix: correct precedence order of env vars
Browse files Browse the repository at this point in the history
  • Loading branch information
Adriano Santos committed Jan 17, 2025
1 parent 7e0cf53 commit cd0f10e
Showing 1 changed file with 2 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -276,7 +276,6 @@ defmodule SpawnOperator.K8s.Proxy.Deployment do
actor_host_function_image = Map.get(host_params, "image")

updated_default_envs =
@default_actor_host_function_env ++
[
%{
"name" => "RELEASE_NAME",
Expand All @@ -292,7 +291,7 @@ defmodule SpawnOperator.K8s.Proxy.Deployment do
"name" => "ERL_FLAGS",
"value" => flags
}
]
] ++ @default_actor_host_function_env

actor_host_function_envs =
if is_nil(task_actors_config) || List.first(Map.values(task_actors_config)) == %{} do
Expand Down Expand Up @@ -356,7 +355,6 @@ defmodule SpawnOperator.K8s.Proxy.Deployment do
actor_host_function_image = Map.get(host_params, "image")

updated_default_envs =
@default_actor_host_function_env ++
[
%{
"name" => "RELEASE_NAME",
Expand All @@ -372,7 +370,7 @@ defmodule SpawnOperator.K8s.Proxy.Deployment do
"name" => "ERL_FLAGS",
"value" => flags
}
]
] ++ @default_actor_host_function_env

actor_host_function_envs =
Map.get(host_params, "env", []) ++
Expand Down

0 comments on commit cd0f10e

Please sign in to comment.