Skip to content

Commit

Permalink
Merge pull request kubernetes#28268 from cjcullen/expr
Browse files Browse the repository at this point in the history
Automatic merge from submit-queue

Make GKE detect-instance-groups work on Mac.

Make the fix from kubernetes#27803 also work on mac.

The GNU `expr` command supports both the `expr match STRING REGEXP` and `expr STRING : REGEXP` command syntax.

The BSD `expr` command only has the `expr STRING : REGEXP` syntax.

@fabioy @a-robinson
  • Loading branch information
k8s-merge-robot authored Jul 2, 2016
2 parents 40b8fb4 + 65ab704 commit 85f75da
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion cluster/gke/util.sh
Original file line number Diff line number Diff line change
Expand Up @@ -318,7 +318,7 @@ function detect-node-instance-groups {
ALL_INSTANCE_GROUP_URLS=${urls[*]}
NODE_INSTANCE_GROUPS=()
for url in "${urls[@]:-}"; do
local igm_zone=$(expr match ${url} '.*/zones/\([a-z0-9-]*\)/')
local igm_zone=$(expr ${url} : '.*/zones/\([a-z0-9-]*\)/')
if [[ "${igm_zone}" == "${ZONE}" ]]; then
NODE_INSTANCE_GROUPS+=("${url##*/}")
fi
Expand Down

0 comments on commit 85f75da

Please sign in to comment.