Skip to content

Commit

Permalink
Merge pull request #431 from eigr/feat/image-pull-policy-on-actor-host
Browse files Browse the repository at this point in the history
imagePullSecrets on deployments for actorhosts
  • Loading branch information
sleipnir authored Mar 4, 2025
2 parents 4af0ddd + d8185d4 commit 2c96e4b
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -195,6 +195,7 @@ defmodule SpawnOperator.K8s.Proxy.Deployment do
}
|> maybe_put_node_selector(topology)
|> maybe_put_node_tolerations(topology)
|> maybe_put_image_pull_secrets(host_params)
|> maybe_put_volumes(params, erlang_mtls_enabled)
|> maybe_set_termination_period(params)
}
Expand Down Expand Up @@ -456,6 +457,15 @@ defmodule SpawnOperator.K8s.Proxy.Deployment do

defp maybe_put_node_tolerations(spec, _), do: spec

defp maybe_put_image_pull_secrets(
spec,
%{"pullSecretRef" => secret_name} = _host_params
) do
Map.merge(spec, %{"imagePullSecrets" => %{"name" => secret_name}})
end

defp maybe_put_image_pull_secrets(spec, _), do: spec

defp maybe_put_ports_to_host_container(spec, %{"ports" => ports}) do
Map.put(spec, "ports", ports)
end
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -193,6 +193,8 @@ defmodule SpawnOperator.Versions.Api.V1.ActorHost do
properties:
image:
type: string
pullSecretsRef:
type: string
volumeMounts:
type: array
items:
Expand Down

0 comments on commit 2c96e4b

Please sign in to comment.