Skip to content
This repository has been archived by the owner on May 10, 2021. It is now read-only.

Commit

Permalink
Fixes string replacement for api service names with multiple slashes.
Browse files Browse the repository at this point in the history
See bcgov/TheOrgBook#867

Signed-off-by: Wade Barnes <wade.barnes@shaw.ca>
  • Loading branch information
WadeBarnes committed Mar 2, 2020
1 parent 85aee20 commit 5fa82af
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ getApiUrl (){
# Results in API_URL=https://dev-demo-api.orgbook.gov.bc.ca/api/v2/
# ================================================================================
if [ ! -z "${API_SERVICE_NAME}" ]; then
_SERVICE_NAME="$(tr '[:lower:]' '[:upper:]' <<< ${API_SERVICE_NAME/-/_})"
_SERVICE_NAME="$(tr '[:lower:]' '[:upper:]' <<< ${API_SERVICE_NAME//-/_})"
_SERVICE_HOST_NAME=${_SERVICE_NAME}_SERVICE_HOST
_SERVICE_PORT_NAME=${_SERVICE_NAME}_SERVICE_PORT

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ getApiUrl (){
# Results in API_URL=https://dev-demo-api.orgbook.gov.bc.ca/api/v2/
# ================================================================================
if [ ! -z "${API_SERVICE_NAME}" ]; then
_SERVICE_NAME="$(tr '[:lower:]' '[:upper:]' <<< ${API_SERVICE_NAME/-/_})"
_SERVICE_NAME="$(tr '[:lower:]' '[:upper:]' <<< ${API_SERVICE_NAME//-/_})"
_SERVICE_HOST_NAME=${_SERVICE_NAME}_SERVICE_HOST
_SERVICE_PORT_NAME=${_SERVICE_NAME}_SERVICE_PORT

Expand Down

0 comments on commit 5fa82af

Please sign in to comment.