Merge pull request #41561 from jamiehannaford/fix-multiple-swift-urls

Automatic merge from submit-queue

Ensure only 1 Swift URL is used in cluster operations

**What this PR does / why we need it**:

Extracts only 1 Swift URL if multiple are returned from Keystone.

**Which issue this PR fixes** *(optional, in `fixes #<issue number>(, fixes #<issue_number>, ...)` format, will close that issue when PR gets merged)*:

https://github.com/kubernetes/kubernetes/issues/34930

**Special notes for your reviewer**:

**Release note**:
```release-note
Heat cluster operations now support environments that have multiple Swift URLs
```
pull/6/head
Kubernetes Submit Queue 2017-04-12 02:16:28 -07:00 committed by GitHub
commit 750d5c3bc5
1 changed files with 1 additions and 1 deletions

View File

@ -194,7 +194,7 @@ function run-heat-script() {
else
rgx="publicURL: (.+)$"
fi
SWIFT_SERVER_URL=$(openstack catalog show object-store --format value | egrep -o "$rgx" | cut -d" " -f2)
SWIFT_SERVER_URL=$(openstack catalog show object-store --format value | egrep -o "$rgx" | cut -d" " -f2 | head -n 1)
fi
local swift_repo_url="${SWIFT_SERVER_URL}/kubernetes"