From 06391b6dd9dcdcf4d03bc638438cacdaf3e5f6be Mon Sep 17 00:00:00 2001 From: Y0UZ45 Date: Sun, 14 Jun 2020 23:57:57 +0300 Subject: [PATCH] Fix kubectl.sh parameter quoting (#6239) If the special parameter "$@" is not quoted, the following command will not work: ./kubectl.sh patch storageclass my-storage-class -p '{"metadata": {"annotations":{"storageclass.kubernetes.io/is-default-class":"true"}}}' --- roles/kubernetes/client/tasks/main.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/roles/kubernetes/client/tasks/main.yml b/roles/kubernetes/client/tasks/main.yml index daeae7d70..663415475 100644 --- a/roles/kubernetes/client/tasks/main.yml +++ b/roles/kubernetes/client/tasks/main.yml @@ -106,7 +106,7 @@ copy: content: | #!/bin/bash - ${BASH_SOURCE%/*}/kubectl --kubeconfig=${BASH_SOURCE%/*}/admin.conf $@ + ${BASH_SOURCE%/*}/kubectl --kubeconfig=${BASH_SOURCE%/*}/admin.conf "$@" dest: "{{ artifacts_dir }}/kubectl.sh" mode: 0755 become: no