Skip to content

Commit

Permalink
feat: Add support for the Korea region of the Sumologic deployment (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
rnishtala-sumo authored Aug 23, 2024
1 parent 6247362 commit e56746e
Show file tree
Hide file tree
Showing 17 changed files with 35 additions and 35 deletions.
10 changes: 5 additions & 5 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),

## [v4.10.0]

### Released 2024-08-22
### Released 2024-08-23

### Breaking Changes

Expand All @@ -21,14 +21,14 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),

### Changed

- test: Added custom pod label tests for global configuration attributes [#3795]
- test: Added custom pod annotation tests for global configuration attributes [#3802]
- test: Added custom service account annotation tests for global configuration attributes [#3803]
- feat: Add support for custom pod label as global configuration [#3795]
- feat: Add support for custom pod annotation as global configuration [#3802]
- feat: Add support for custom service account annotation as global configuration [#3803]
- feat: add support for kubernetes 1.30 for GKE [#3804]
- feat: add support for kubernetes 1.30 for EKS [#3804]
- feat: add support for kubernetes 1.30 for AKS [#3804]
- feat: add support for kubernetes 4.16 for OpenShift [#3804]
- test: Added custom image pull secrets tests for global configuration attributes [#3808]
- feat: Add support for custom image pull secrets tests as global configuration [#3808]
- chore: update OpenTelemetry Collector to 0.104.0-sumo-1 [#3829]

### Fixed
Expand Down
2 changes: 1 addition & 1 deletion deploy/helm/sumologic/conf/setup/monitors.sh
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ if [[ -z "${MONITORS_FOLDER_ID}" ]]; then

# extract environment from SUMOLOGIC_BASE_URL
# see: https://help.sumologic.com/docs/api/getting-started/#sumo-logic-endpoints-by-deployment-and-firewall-security
SUMOLOGIC_ENV=$( echo "${SUMOLOGIC_BASE_URL}" | sed -E 's/https:\/\/.*(au|ca|de|eu|fed|in|jp|us2)\.sumologic\.com.*/\1/' )
SUMOLOGIC_ENV=$( echo "${SUMOLOGIC_BASE_URL}" | sed -E 's/https:\/\/.*(au|ca|de|eu|fed|in|jp|kr|us2)\.sumologic\.com.*/\1/' )
if [[ "${SUMOLOGIC_BASE_URL}" == "${SUMOLOGIC_ENV}" ]] ; then
SUMOLOGIC_ENV="us1"
fi
Expand Down
2 changes: 1 addition & 1 deletion deploy/helm/sumologic/conf/setup/setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ function fix_sumo_base_url() {
| grep -Fi location )"

if [[ ! ${OPTIONAL_REDIRECTION} =~ ^\s*$ ]]; then
BASE_URL=$( echo "${OPTIONAL_REDIRECTION}" | sed -E 's/.*: (https:\/\/.*(au|ca|de|eu|fed|in|jp|us2)?\.sumologic\.com\/api\/).*/\1/' )
BASE_URL=$( echo "${OPTIONAL_REDIRECTION}" | sed -E 's/.*: (https:\/\/.*(au|ca|de|eu|fed|in|jp|kr|us2)?\.sumologic\.com\/api\/).*/\1/' )
fi

BASE_URL=${BASE_URL%v1*}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,7 @@ data:
# extract environment from SUMOLOGIC_BASE_URL
# see: https://help.sumologic.com/docs/api/getting-started/#sumo-logic-endpoints-by-deployment-and-firewall-security
SUMOLOGIC_ENV=$( echo "${SUMOLOGIC_BASE_URL}" | sed -E 's/https:\/\/.*(au|ca|de|eu|fed|in|jp|us2)\.sumologic\.com.*/\1/' )
SUMOLOGIC_ENV=$( echo "${SUMOLOGIC_BASE_URL}" | sed -E 's/https:\/\/.*(au|ca|de|eu|fed|in|jp|kr|us2)\.sumologic\.com.*/\1/' )
if [[ "${SUMOLOGIC_BASE_URL}" == "${SUMOLOGIC_ENV}" ]] ; then
SUMOLOGIC_ENV="us1"
fi
Expand Down Expand Up @@ -400,7 +400,7 @@ data:
| grep -Fi location )"
if [[ ! ${OPTIONAL_REDIRECTION} =~ ^\s*$ ]]; then
BASE_URL=$( echo "${OPTIONAL_REDIRECTION}" | sed -E 's/.*: (https:\/\/.*(au|ca|de|eu|fed|in|jp|us2)?\.sumologic\.com\/api\/).*/\1/' )
BASE_URL=$( echo "${OPTIONAL_REDIRECTION}" | sed -E 's/.*: (https:\/\/.*(au|ca|de|eu|fed|in|jp|kr|us2)?\.sumologic\.com\/api\/).*/\1/' )
fi
BASE_URL=${BASE_URL%v1*}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,7 @@ data:
# extract environment from SUMOLOGIC_BASE_URL
# see: https://help.sumologic.com/docs/api/getting-started/#sumo-logic-endpoints-by-deployment-and-firewall-security
SUMOLOGIC_ENV=$( echo "${SUMOLOGIC_BASE_URL}" | sed -E 's/https:\/\/.*(au|ca|de|eu|fed|in|jp|us2)\.sumologic\.com.*/\1/' )
SUMOLOGIC_ENV=$( echo "${SUMOLOGIC_BASE_URL}" | sed -E 's/https:\/\/.*(au|ca|de|eu|fed|in|jp|kr|us2)\.sumologic\.com.*/\1/' )
if [[ "${SUMOLOGIC_BASE_URL}" == "${SUMOLOGIC_ENV}" ]] ; then
SUMOLOGIC_ENV="us1"
fi
Expand Down Expand Up @@ -400,7 +400,7 @@ data:
| grep -Fi location )"
if [[ ! ${OPTIONAL_REDIRECTION} =~ ^\s*$ ]]; then
BASE_URL=$( echo "${OPTIONAL_REDIRECTION}" | sed -E 's/.*: (https:\/\/.*(au|ca|de|eu|fed|in|jp|us2)?\.sumologic\.com\/api\/).*/\1/' )
BASE_URL=$( echo "${OPTIONAL_REDIRECTION}" | sed -E 's/.*: (https:\/\/.*(au|ca|de|eu|fed|in|jp|kr|us2)?\.sumologic\.com\/api\/).*/\1/' )
fi
BASE_URL=${BASE_URL%v1*}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,7 @@ data:
# extract environment from SUMOLOGIC_BASE_URL
# see: https://help.sumologic.com/docs/api/getting-started/#sumo-logic-endpoints-by-deployment-and-firewall-security
SUMOLOGIC_ENV=$( echo "${SUMOLOGIC_BASE_URL}" | sed -E 's/https:\/\/.*(au|ca|de|eu|fed|in|jp|us2)\.sumologic\.com.*/\1/' )
SUMOLOGIC_ENV=$( echo "${SUMOLOGIC_BASE_URL}" | sed -E 's/https:\/\/.*(au|ca|de|eu|fed|in|jp|kr|us2)\.sumologic\.com.*/\1/' )
if [[ "${SUMOLOGIC_BASE_URL}" == "${SUMOLOGIC_ENV}" ]] ; then
SUMOLOGIC_ENV="us1"
fi
Expand Down Expand Up @@ -400,7 +400,7 @@ data:
| grep -Fi location )"
if [[ ! ${OPTIONAL_REDIRECTION} =~ ^\s*$ ]]; then
BASE_URL=$( echo "${OPTIONAL_REDIRECTION}" | sed -E 's/.*: (https:\/\/.*(au|ca|de|eu|fed|in|jp|us2)?\.sumologic\.com\/api\/).*/\1/' )
BASE_URL=$( echo "${OPTIONAL_REDIRECTION}" | sed -E 's/.*: (https:\/\/.*(au|ca|de|eu|fed|in|jp|kr|us2)?\.sumologic\.com\/api\/).*/\1/' )
fi
BASE_URL=${BASE_URL%v1*}
Expand Down
4 changes: 2 additions & 2 deletions tests/helm/testdata/goldenfile/terraform/custom.output.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,7 @@ data:
# extract environment from SUMOLOGIC_BASE_URL
# see: https://help.sumologic.com/docs/api/getting-started/#sumo-logic-endpoints-by-deployment-and-firewall-security
SUMOLOGIC_ENV=$( echo "${SUMOLOGIC_BASE_URL}" | sed -E 's/https:\/\/.*(au|ca|de|eu|fed|in|jp|us2)\.sumologic\.com.*/\1/' )
SUMOLOGIC_ENV=$( echo "${SUMOLOGIC_BASE_URL}" | sed -E 's/https:\/\/.*(au|ca|de|eu|fed|in|jp|kr|us2)\.sumologic\.com.*/\1/' )
if [[ "${SUMOLOGIC_BASE_URL}" == "${SUMOLOGIC_ENV}" ]] ; then
SUMOLOGIC_ENV="us1"
fi
Expand Down Expand Up @@ -400,7 +400,7 @@ data:
| grep -Fi location )"
if [[ ! ${OPTIONAL_REDIRECTION} =~ ^\s*$ ]]; then
BASE_URL=$( echo "${OPTIONAL_REDIRECTION}" | sed -E 's/.*: (https:\/\/.*(au|ca|de|eu|fed|in|jp|us2)?\.sumologic\.com\/api\/).*/\1/' )
BASE_URL=$( echo "${OPTIONAL_REDIRECTION}" | sed -E 's/.*: (https:\/\/.*(au|ca|de|eu|fed|in|jp|kr|us2)?\.sumologic\.com\/api\/).*/\1/' )
fi
BASE_URL=${BASE_URL%v1*}
Expand Down
4 changes: 2 additions & 2 deletions tests/helm/testdata/goldenfile/terraform/default.output.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,7 @@ data:
# extract environment from SUMOLOGIC_BASE_URL
# see: https://help.sumologic.com/docs/api/getting-started/#sumo-logic-endpoints-by-deployment-and-firewall-security
SUMOLOGIC_ENV=$( echo "${SUMOLOGIC_BASE_URL}" | sed -E 's/https:\/\/.*(au|ca|de|eu|fed|in|jp|us2)\.sumologic\.com.*/\1/' )
SUMOLOGIC_ENV=$( echo "${SUMOLOGIC_BASE_URL}" | sed -E 's/https:\/\/.*(au|ca|de|eu|fed|in|jp|kr|us2)\.sumologic\.com.*/\1/' )
if [[ "${SUMOLOGIC_BASE_URL}" == "${SUMOLOGIC_ENV}" ]] ; then
SUMOLOGIC_ENV="us1"
fi
Expand Down Expand Up @@ -400,7 +400,7 @@ data:
| grep -Fi location )"
if [[ ! ${OPTIONAL_REDIRECTION} =~ ^\s*$ ]]; then
BASE_URL=$( echo "${OPTIONAL_REDIRECTION}" | sed -E 's/.*: (https:\/\/.*(au|ca|de|eu|fed|in|jp|us2)?\.sumologic\.com\/api\/).*/\1/' )
BASE_URL=$( echo "${OPTIONAL_REDIRECTION}" | sed -E 's/.*: (https:\/\/.*(au|ca|de|eu|fed|in|jp|kr|us2)?\.sumologic\.com\/api\/).*/\1/' )
fi
BASE_URL=${BASE_URL%v1*}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,7 @@ data:
# extract environment from SUMOLOGIC_BASE_URL
# see: https://help.sumologic.com/docs/api/getting-started/#sumo-logic-endpoints-by-deployment-and-firewall-security
SUMOLOGIC_ENV=$( echo "${SUMOLOGIC_BASE_URL}" | sed -E 's/https:\/\/.*(au|ca|de|eu|fed|in|jp|us2)\.sumologic\.com.*/\1/' )
SUMOLOGIC_ENV=$( echo "${SUMOLOGIC_BASE_URL}" | sed -E 's/https:\/\/.*(au|ca|de|eu|fed|in|jp|kr|us2)\.sumologic\.com.*/\1/' )
if [[ "${SUMOLOGIC_BASE_URL}" == "${SUMOLOGIC_ENV}" ]] ; then
SUMOLOGIC_ENV="us1"
fi
Expand Down Expand Up @@ -400,7 +400,7 @@ data:
| grep -Fi location )"
if [[ ! ${OPTIONAL_REDIRECTION} =~ ^\s*$ ]]; then
BASE_URL=$( echo "${OPTIONAL_REDIRECTION}" | sed -E 's/.*: (https:\/\/.*(au|ca|de|eu|fed|in|jp|us2)?\.sumologic\.com\/api\/).*/\1/' )
BASE_URL=$( echo "${OPTIONAL_REDIRECTION}" | sed -E 's/.*: (https:\/\/.*(au|ca|de|eu|fed|in|jp|kr|us2)?\.sumologic\.com\/api\/).*/\1/' )
fi
BASE_URL=${BASE_URL%v1*}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,7 @@ data:
# extract environment from SUMOLOGIC_BASE_URL
# see: https://help.sumologic.com/docs/api/getting-started/#sumo-logic-endpoints-by-deployment-and-firewall-security
SUMOLOGIC_ENV=$( echo "${SUMOLOGIC_BASE_URL}" | sed -E 's/https:\/\/.*(au|ca|de|eu|fed|in|jp|us2)\.sumologic\.com.*/\1/' )
SUMOLOGIC_ENV=$( echo "${SUMOLOGIC_BASE_URL}" | sed -E 's/https:\/\/.*(au|ca|de|eu|fed|in|jp|kr|us2)\.sumologic\.com.*/\1/' )
if [[ "${SUMOLOGIC_BASE_URL}" == "${SUMOLOGIC_ENV}" ]] ; then
SUMOLOGIC_ENV="us1"
fi
Expand Down Expand Up @@ -400,7 +400,7 @@ data:
| grep -Fi location )"
if [[ ! ${OPTIONAL_REDIRECTION} =~ ^\s*$ ]]; then
BASE_URL=$( echo "${OPTIONAL_REDIRECTION}" | sed -E 's/.*: (https:\/\/.*(au|ca|de|eu|fed|in|jp|us2)?\.sumologic\.com\/api\/).*/\1/' )
BASE_URL=$( echo "${OPTIONAL_REDIRECTION}" | sed -E 's/.*: (https:\/\/.*(au|ca|de|eu|fed|in|jp|kr|us2)?\.sumologic\.com\/api\/).*/\1/' )
fi
BASE_URL=${BASE_URL%v1*}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,7 @@ data:
# extract environment from SUMOLOGIC_BASE_URL
# see: https://help.sumologic.com/docs/api/getting-started/#sumo-logic-endpoints-by-deployment-and-firewall-security
SUMOLOGIC_ENV=$( echo "${SUMOLOGIC_BASE_URL}" | sed -E 's/https:\/\/.*(au|ca|de|eu|fed|in|jp|us2)\.sumologic\.com.*/\1/' )
SUMOLOGIC_ENV=$( echo "${SUMOLOGIC_BASE_URL}" | sed -E 's/https:\/\/.*(au|ca|de|eu|fed|in|jp|kr|us2)\.sumologic\.com.*/\1/' )
if [[ "${SUMOLOGIC_BASE_URL}" == "${SUMOLOGIC_ENV}" ]] ; then
SUMOLOGIC_ENV="us1"
fi
Expand Down Expand Up @@ -400,7 +400,7 @@ data:
| grep -Fi location )"
if [[ ! ${OPTIONAL_REDIRECTION} =~ ^\s*$ ]]; then
BASE_URL=$( echo "${OPTIONAL_REDIRECTION}" | sed -E 's/.*: (https:\/\/.*(au|ca|de|eu|fed|in|jp|us2)?\.sumologic\.com\/api\/).*/\1/' )
BASE_URL=$( echo "${OPTIONAL_REDIRECTION}" | sed -E 's/.*: (https:\/\/.*(au|ca|de|eu|fed|in|jp|kr|us2)?\.sumologic\.com\/api\/).*/\1/' )
fi
BASE_URL=${BASE_URL%v1*}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,7 @@ data:
# extract environment from SUMOLOGIC_BASE_URL
# see: https://help.sumologic.com/docs/api/getting-started/#sumo-logic-endpoints-by-deployment-and-firewall-security
SUMOLOGIC_ENV=$( echo "${SUMOLOGIC_BASE_URL}" | sed -E 's/https:\/\/.*(au|ca|de|eu|fed|in|jp|us2)\.sumologic\.com.*/\1/' )
SUMOLOGIC_ENV=$( echo "${SUMOLOGIC_BASE_URL}" | sed -E 's/https:\/\/.*(au|ca|de|eu|fed|in|jp|kr|us2)\.sumologic\.com.*/\1/' )
if [[ "${SUMOLOGIC_BASE_URL}" == "${SUMOLOGIC_ENV}" ]] ; then
SUMOLOGIC_ENV="us1"
fi
Expand Down Expand Up @@ -400,7 +400,7 @@ data:
| grep -Fi location )"
if [[ ! ${OPTIONAL_REDIRECTION} =~ ^\s*$ ]]; then
BASE_URL=$( echo "${OPTIONAL_REDIRECTION}" | sed -E 's/.*: (https:\/\/.*(au|ca|de|eu|fed|in|jp|us2)?\.sumologic\.com\/api\/).*/\1/' )
BASE_URL=$( echo "${OPTIONAL_REDIRECTION}" | sed -E 's/.*: (https:\/\/.*(au|ca|de|eu|fed|in|jp|kr|us2)?\.sumologic\.com\/api\/).*/\1/' )
fi
BASE_URL=${BASE_URL%v1*}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,7 @@ data:
# extract environment from SUMOLOGIC_BASE_URL
# see: https://help.sumologic.com/docs/api/getting-started/#sumo-logic-endpoints-by-deployment-and-firewall-security
SUMOLOGIC_ENV=$( echo "${SUMOLOGIC_BASE_URL}" | sed -E 's/https:\/\/.*(au|ca|de|eu|fed|in|jp|us2)\.sumologic\.com.*/\1/' )
SUMOLOGIC_ENV=$( echo "${SUMOLOGIC_BASE_URL}" | sed -E 's/https:\/\/.*(au|ca|de|eu|fed|in|jp|kr|us2)\.sumologic\.com.*/\1/' )
if [[ "${SUMOLOGIC_BASE_URL}" == "${SUMOLOGIC_ENV}" ]] ; then
SUMOLOGIC_ENV="us1"
fi
Expand Down Expand Up @@ -400,7 +400,7 @@ data:
| grep -Fi location )"
if [[ ! ${OPTIONAL_REDIRECTION} =~ ^\s*$ ]]; then
BASE_URL=$( echo "${OPTIONAL_REDIRECTION}" | sed -E 's/.*: (https:\/\/.*(au|ca|de|eu|fed|in|jp|us2)?\.sumologic\.com\/api\/).*/\1/' )
BASE_URL=$( echo "${OPTIONAL_REDIRECTION}" | sed -E 's/.*: (https:\/\/.*(au|ca|de|eu|fed|in|jp|kr|us2)?\.sumologic\.com\/api\/).*/\1/' )
fi
BASE_URL=${BASE_URL%v1*}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,7 @@ data:
# extract environment from SUMOLOGIC_BASE_URL
# see: https://help.sumologic.com/docs/api/getting-started/#sumo-logic-endpoints-by-deployment-and-firewall-security
SUMOLOGIC_ENV=$( echo "${SUMOLOGIC_BASE_URL}" | sed -E 's/https:\/\/.*(au|ca|de|eu|fed|in|jp|us2)\.sumologic\.com.*/\1/' )
SUMOLOGIC_ENV=$( echo "${SUMOLOGIC_BASE_URL}" | sed -E 's/https:\/\/.*(au|ca|de|eu|fed|in|jp|kr|us2)\.sumologic\.com.*/\1/' )
if [[ "${SUMOLOGIC_BASE_URL}" == "${SUMOLOGIC_ENV}" ]] ; then
SUMOLOGIC_ENV="us1"
fi
Expand Down Expand Up @@ -400,7 +400,7 @@ data:
| grep -Fi location )"
if [[ ! ${OPTIONAL_REDIRECTION} =~ ^\s*$ ]]; then
BASE_URL=$( echo "${OPTIONAL_REDIRECTION}" | sed -E 's/.*: (https:\/\/.*(au|ca|de|eu|fed|in|jp|us2)?\.sumologic\.com\/api\/).*/\1/' )
BASE_URL=$( echo "${OPTIONAL_REDIRECTION}" | sed -E 's/.*: (https:\/\/.*(au|ca|de|eu|fed|in|jp|kr|us2)?\.sumologic\.com\/api\/).*/\1/' )
fi
BASE_URL=${BASE_URL%v1*}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,7 @@ data:
# extract environment from SUMOLOGIC_BASE_URL
# see: https://help.sumologic.com/docs/api/getting-started/#sumo-logic-endpoints-by-deployment-and-firewall-security
SUMOLOGIC_ENV=$( echo "${SUMOLOGIC_BASE_URL}" | sed -E 's/https:\/\/.*(au|ca|de|eu|fed|in|jp|us2)\.sumologic\.com.*/\1/' )
SUMOLOGIC_ENV=$( echo "${SUMOLOGIC_BASE_URL}" | sed -E 's/https:\/\/.*(au|ca|de|eu|fed|in|jp|kr|us2)\.sumologic\.com.*/\1/' )
if [[ "${SUMOLOGIC_BASE_URL}" == "${SUMOLOGIC_ENV}" ]] ; then
SUMOLOGIC_ENV="us1"
fi
Expand Down Expand Up @@ -400,7 +400,7 @@ data:
| grep -Fi location )"
if [[ ! ${OPTIONAL_REDIRECTION} =~ ^\s*$ ]]; then
BASE_URL=$( echo "${OPTIONAL_REDIRECTION}" | sed -E 's/.*: (https:\/\/.*(au|ca|de|eu|fed|in|jp|us2)?\.sumologic\.com\/api\/).*/\1/' )
BASE_URL=$( echo "${OPTIONAL_REDIRECTION}" | sed -E 's/.*: (https:\/\/.*(au|ca|de|eu|fed|in|jp|kr|us2)?\.sumologic\.com\/api\/).*/\1/' )
fi
BASE_URL=${BASE_URL%v1*}
Expand Down
4 changes: 2 additions & 2 deletions tests/helm/testdata/goldenfile/terraform/traces.output.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,7 @@ data:
# extract environment from SUMOLOGIC_BASE_URL
# see: https://help.sumologic.com/docs/api/getting-started/#sumo-logic-endpoints-by-deployment-and-firewall-security
SUMOLOGIC_ENV=$( echo "${SUMOLOGIC_BASE_URL}" | sed -E 's/https:\/\/.*(au|ca|de|eu|fed|in|jp|us2)\.sumologic\.com.*/\1/' )
SUMOLOGIC_ENV=$( echo "${SUMOLOGIC_BASE_URL}" | sed -E 's/https:\/\/.*(au|ca|de|eu|fed|in|jp|kr|us2)\.sumologic\.com.*/\1/' )
if [[ "${SUMOLOGIC_BASE_URL}" == "${SUMOLOGIC_ENV}" ]] ; then
SUMOLOGIC_ENV="us1"
fi
Expand Down Expand Up @@ -400,7 +400,7 @@ data:
| grep -Fi location )"
if [[ ! ${OPTIONAL_REDIRECTION} =~ ^\s*$ ]]; then
BASE_URL=$( echo "${OPTIONAL_REDIRECTION}" | sed -E 's/.*: (https:\/\/.*(au|ca|de|eu|fed|in|jp|us2)?\.sumologic\.com\/api\/).*/\1/' )
BASE_URL=$( echo "${OPTIONAL_REDIRECTION}" | sed -E 's/.*: (https:\/\/.*(au|ca|de|eu|fed|in|jp|kr|us2)?\.sumologic\.com\/api\/).*/\1/' )
fi
BASE_URL=${BASE_URL%v1*}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -305,7 +305,7 @@ data:
# extract environment from SUMOLOGIC_BASE_URL
# see: https://help.sumologic.com/docs/api/getting-started/#sumo-logic-endpoints-by-deployment-and-firewall-security
SUMOLOGIC_ENV=$( echo "${SUMOLOGIC_BASE_URL}" | sed -E 's/https:\/\/.*(au|ca|de|eu|fed|in|jp|us2)\.sumologic\.com.*/\1/' )
SUMOLOGIC_ENV=$( echo "${SUMOLOGIC_BASE_URL}" | sed -E 's/https:\/\/.*(au|ca|de|eu|fed|in|jp|kr|us2)\.sumologic\.com.*/\1/' )
if [[ "${SUMOLOGIC_BASE_URL}" == "${SUMOLOGIC_ENV}" ]] ; then
SUMOLOGIC_ENV="us1"
fi
Expand Down Expand Up @@ -400,7 +400,7 @@ data:
| grep -Fi location )"
if [[ ! ${OPTIONAL_REDIRECTION} =~ ^\s*$ ]]; then
BASE_URL=$( echo "${OPTIONAL_REDIRECTION}" | sed -E 's/.*: (https:\/\/.*(au|ca|de|eu|fed|in|jp|us2)?\.sumologic\.com\/api\/).*/\1/' )
BASE_URL=$( echo "${OPTIONAL_REDIRECTION}" | sed -E 's/.*: (https:\/\/.*(au|ca|de|eu|fed|in|jp|kr|us2)?\.sumologic\.com\/api\/).*/\1/' )
fi
BASE_URL=${BASE_URL%v1*}
Expand Down

0 comments on commit e56746e

Please sign in to comment.