mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-31 23:37:01 +00:00
Merge pull request #23612 from mikedanese/addon-fix
Automatic merge from submit-queue use apply instead of create to setup namespaces and tokens in addon manager when the addon manager restarts, it takes ~15 minutes (1000 seconds) to start the sync loop because it retries creation of namespace and tokens 100 times. Create fails if the tokens already exist. Just use apply.
This commit is contained in:
commit
5be819b607
@ -59,7 +59,7 @@ function create-resource-from-string() {
|
||||
local -r config_name=$4;
|
||||
local -r namespace=$5;
|
||||
while [ ${tries} -gt 0 ]; do
|
||||
echo "${config_string}" | ${KUBECTL} --namespace="${namespace}" create -f - && \
|
||||
echo "${config_string}" | ${KUBECTL} --namespace="${namespace}" apply -f - && \
|
||||
echo "== Successfully started ${config_name} in namespace ${namespace} at $(date -Is)" && \
|
||||
return 0;
|
||||
let tries=tries-1;
|
||||
|
Loading…
Reference in New Issue
Block a user