Commit c3a32410 authored by k8s-merge-robot's avatar k8s-merge-robot Committed by GitHub

Merge pull request #27592 from nikhiljindal/fixFedTest

Automatic merge from submit-queue federation: reverse the order of creating controller manager and secret since controller requires secret Ref #26762 federation-controller-manager fails if the secret is not there when it comes up: https://github.com/kubernetes/kubernetes/blob/970104df3199eeb30710d1067da28f952ae36403/federation/cmd/federation-controller-manager/app/controllermanager.go#L82. Updating the bring up scripts to first create the secrets and then create the deployments. @kubernetes/sig-cluster-federation @mml
parents 9f607c52 71e1fea2
......@@ -145,9 +145,6 @@ function create-federation-api-objects {
FEDERATION_API_TOKEN="$(dd if=/dev/urandom bs=128 count=1 2>/dev/null | base64 | tr -d "=+/" | dd bs=32 count=1 2>/dev/null)"
export FEDERATION_API_KNOWN_TOKENS="${FEDERATION_API_TOKEN},admin,admin"
$template "${manifests_root}/federation-apiserver-"{deployment,secrets}".yaml" | $host_kubectl create -f -
$template "${manifests_root}/federation-controller-manager-deployment.yaml" | $host_kubectl create -f -
# Create a kubeconfig with credentails for federation-apiserver. We will
# then use this kubeconfig to create a secret which the federation
# controller manager can use to talk to the federation-apiserver.
......@@ -169,6 +166,9 @@ function create-federation-api-objects {
$host_kubectl create secret generic ${name} --from-file="${dir}/kubeconfig" --namespace="${FEDERATION_NAMESPACE}"
done
$template "${manifests_root}/federation-apiserver-"{deployment,secrets}".yaml" | $host_kubectl create -f -
$template "${manifests_root}/federation-controller-manager-deployment.yaml" | $host_kubectl create -f -
# Update the users kubeconfig to include federation-apiserver credentials.
CONTEXT=federation-cluster \
KUBE_BEARER_TOKEN="$FEDERATION_API_TOKEN" \
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment