File tree Expand file tree Collapse file tree 4 files changed +10
-9
lines changed Expand file tree Collapse file tree 4 files changed +10
-9
lines changed Original file line number Diff line number Diff line change @@ -33,9 +33,13 @@ function get-node-instance-metadata-from-file {
33
33
echo " ${metadata} "
34
34
}
35
35
36
- # $1: template name (required).
36
+ # Assumed vars:
37
+ # scope_flags
38
+ # Parameters:
39
+ # $1: template name (required).
37
40
function create-linux-node-instance-template {
38
41
local template_name=" $1 "
39
42
ensure-gci-metadata-files
43
+ # shellcheck disable=2154 # 'scope_flags' is assigned by upstream
40
44
create-node-template " ${template_name} " " ${scope_flags[*]} " " $( get-node-instance-metadata-from-file) " " " " linux"
41
45
}
Original file line number Diff line number Diff line change @@ -25,7 +25,7 @@ set -o errexit
25
25
set -o nounset
26
26
set -o pipefail
27
27
28
- KUBE_ROOT=$( dirname " ${BASH_SOURCE} " ) /..
28
+ KUBE_ROOT=$( dirname " ${BASH_SOURCE[0] } " ) /..
29
29
source " ${KUBE_ROOT} /hack/lib/init.sh"
30
30
31
31
KUBECTL=" ${KUBE_OUTPUT_HOSTBIN} /kubectl"
@@ -57,7 +57,7 @@ declare -a resources=(
57
57
)
58
58
59
59
# Find all the namespaces.
60
- namespaces=( $( " ${KUBECTL} " get namespaces -o go-template=" {{range.items}}{{.metadata.name}} {{end}}" ) )
60
+ IFS= " " read -r -a namespaces <<< " $(" ${KUBECTL} " get namespaces -o go-template=" {{range.items}}{{.metadata.name}} {{end}}" )"
61
61
if [ -z " ${namespaces:- } " ]
62
62
then
63
63
echo " Unexpected: No namespace found. Nothing to do."
74
74
# TODO hopefully we can remove this once we use dynamic discovery of gettable/updateable
75
75
# resources.
76
76
set +e
77
- instances=( $( " ${KUBECTL} " get " ${resource} " --namespace=" ${namespace} " -o go-template=" {{range.items}}{{.metadata.name}} {{end}}" ) )
77
+ IFS= " " read -r -a instances <<< " $(" ${KUBECTL} " get " ${resource} " --namespace=" ${namespace} " -o go-template=" {{range.items}}{{.metadata.name}} {{end}}" )"
78
78
result=$?
79
79
set -e
80
80
Original file line number Diff line number Diff line change 12
12
./cluster/gce/gci/health-monitor.sh
13
13
./cluster/gce/gci/master-helper.sh
14
14
./cluster/gce/gci/mounter/stage-upload.sh
15
- ./cluster/gce/gci/node-helper.sh
16
15
./cluster/gce/gci/shutdown.sh
17
16
./cluster/gce/list-resources.sh
18
17
./cluster/gce/upgrade-aliases.sh
28
27
./cluster/test-e2e.sh
29
28
./cluster/test-network.sh
30
29
./cluster/test-smoke.sh
31
- ./cluster/update-storage-objects.sh
32
30
./cluster/validate-cluster.sh
33
31
./hack/cherry_pick_pull.sh
34
32
./hack/ginkgo-e2e.sh
69
67
./hack/update-generated-kms-dockerized.sh
70
68
./hack/update-generated-protobuf-dockerized.sh
71
69
./hack/update-generated-runtime-dockerized.sh
72
- ./hack/update-generated-runtime.sh
73
70
./hack/update-godep-licenses.sh
74
71
./hack/update-gofmt.sh
75
72
./hack/update-openapi-spec.sh
Original file line number Diff line number Diff line change @@ -18,12 +18,12 @@ set -o errexit
18
18
set -o nounset
19
19
set -o pipefail
20
20
21
- KUBE_ROOT=$( dirname " ${BASH_SOURCE} " ) /..
21
+ KUBE_ROOT=$( dirname " ${BASH_SOURCE[0] } " ) /..
22
22
23
23
# NOTE: All output from this script needs to be copied back to the calling
24
24
# source tree. This is managed in kube::build::copy_output in build/common.sh.
25
25
# If the output set is changed update that function.
26
26
27
- ${KUBE_ROOT} /build/run.sh hack/update-generated-runtime-dockerized.sh " $@ "
27
+ " ${KUBE_ROOT} /build/run.sh" hack/update-generated-runtime-dockerized.sh " $@ "
28
28
29
29
# ex: ts=2 sw=2 et filetype=sh
You can’t perform that action at this time.
0 commit comments