fix: revert azure patch and fix the order parameters in the function

Signed-off-by: Marco Amador <amador.marco@gmail.com>
pull/1119/head
Marco Amador 4 years ago
parent 585b97c462
commit e6132e36ba

@ -47,9 +47,9 @@ spec:
apply-secret() { apply-secret() {
/kbin/kubectl create secret docker-registry "${1}" \ /kbin/kubectl create secret docker-registry "${1}" \
--docker-server="${2}" \ --docker-password="${2}" \
--docker-username="${3}" \ --docker-username="${3}" \
--docker-password="${4}" \ --docker-server="${4}" \
--dry-run=client -o=yaml \ --dry-run=client -o=yaml \
| grep -v "creationTimestamp:" \ | grep -v "creationTimestamp:" \
| /kbin/kubectl apply -f - | /kbin/kubectl apply -f -

@ -49,9 +49,9 @@ spec:
apply-secret() { apply-secret() {
/kbin/kubectl create secret docker-registry "${1}" \ /kbin/kubectl create secret docker-registry "${1}" \
--docker-server="${2}" \ --docker-passwrod="${2}" \
--docker-username="${3}" \ --docker-username="${3}" \
--docker-password="${4}" \ --docker-server="${4}" \
--dry-run=client -o=yaml \ --dry-run=client -o=yaml \
| grep -v "creationTimestamp:" \ | grep -v "creationTimestamp:" \
| /kbin/kubectl apply -f - | /kbin/kubectl apply -f -

@ -23,14 +23,7 @@ spec:
read token server <<< "${output}" read token server <<< "${output}"
user="00000000-0000-0000-0000-000000000000" user="00000000-0000-0000-0000-000000000000"
echo "Creating secret: ${KUBE_SECRET}" apply-secret "${KUBE_SECRET}" "${token}" "${user}" "${server}"
/kbin/kubectl create secret docker-registry "${KUBE_SECRET}" \
--docker-server="${server}" \
--docker-username="00000000-0000-0000-0000-000000000000" \
--docker-password="${token}" \
--dry-run=client -o=yaml \
| grep -v "creationTimestamp:" \
| /kbin/kubectl apply -f -
echo "Finished ACR token sync -- $(date)" echo "Finished ACR token sync -- $(date)"
echo echo

@ -23,8 +23,8 @@ spec:
user="00000000-0000-0000-0000-000000000000" user="00000000-0000-0000-0000-000000000000"
echo "Creating secret: ${KUBE_SECRET}" echo "Creating secret: ${KUBE_SECRET}"
apply-secret "${KUBE_SECRET}" "${server}" "${user}" "${token}" apply-secret "${KUBE_SECRET}" "${token}" "${user}" "${server}"
echo "Finished ECR token sync -- $(date)" echo "Finished ACR token sync -- $(date)"
echo echo
} }

Loading…
Cancel
Save