mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-22 19:31:44 +00:00
Merge pull request #69522 from wojtek-t/fix_env_setup
Fix overwriting env variables in kube-apiserver manifest
This commit is contained in:
commit
4966faab36
@ -1763,16 +1763,16 @@ function start-kube-apiserver {
|
||||
|
||||
local container_env=""
|
||||
if [[ -n "${ENABLE_CACHE_MUTATION_DETECTOR:-}" ]]; then
|
||||
container_env="\"name\": \"KUBE_CACHE_MUTATION_DETECTOR\", \"value\": \"${ENABLE_CACHE_MUTATION_DETECTOR}\""
|
||||
container_env+="{\"name\": \"KUBE_CACHE_MUTATION_DETECTOR\", \"value\": \"${ENABLE_CACHE_MUTATION_DETECTOR}\"}"
|
||||
fi
|
||||
if [[ -n "${ENABLE_PATCH_CONVERSION_DETECTOR:-}" ]]; then
|
||||
if [[ -n "${container_env}" ]]; then
|
||||
container_env="${container_env}, "
|
||||
fi
|
||||
container_env="\"name\": \"KUBE_PATCH_CONVERSION_DETECTOR\", \"value\": \"${ENABLE_PATCH_CONVERSION_DETECTOR}\""
|
||||
container_env+="{\"name\": \"KUBE_PATCH_CONVERSION_DETECTOR\", \"value\": \"${ENABLE_PATCH_CONVERSION_DETECTOR}\"}"
|
||||
fi
|
||||
if [[ -n "${container_env}" ]]; then
|
||||
container_env="\"env\":[{${container_env}}],"
|
||||
container_env="\"env\":[${container_env}],"
|
||||
fi
|
||||
|
||||
local -r src_file="${src_dir}/kube-apiserver.manifest"
|
||||
|
Loading…
Reference in New Issue
Block a user