diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 3c6d792..cd09a82 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -26,9 +26,9 @@ jobs: run: git fetch --prune --unshallow - name: Set up Go - uses: actions/setup-go@v2 + uses: actions/setup-go@v5 with: - go-version: 1.17 + go-version: 1.18 - name: Import GPG key id: import_gpg diff --git a/DEVELOPMENT.md b/DEVELOPMENT.md index fa6e7fa..e5d417e 100644 --- a/DEVELOPMENT.md +++ b/DEVELOPMENT.md @@ -55,7 +55,7 @@ In order to test the provider installed locally, the provider block will have to terraform { required_providers { aquasec = { - version = "0.8.27" + version = "0.8.28" source = "terraform-provider-aquasec/aquasec/aquasec" } } diff --git a/GNUmakefile b/GNUmakefile index 1570d56..cce6e3f 100644 --- a/GNUmakefile +++ b/GNUmakefile @@ -6,7 +6,7 @@ HOSTNAME := github.com NAMESPACE := aquasec NAME := aquasec BINARY := terraform-provider-${NAME} -VERSION := 0.8.27 +VERSION := 0.8.28 OS_ARCH := $(shell go env GOOS)_$(shell go env GOARCH) default: build diff --git a/README.md b/README.md index f7dbe56..f190102 100644 --- a/README.md +++ b/README.md @@ -43,7 +43,7 @@ To quickly get started using the Aquasec provider for Terraform, configure the p terraform { required_providers { aquasec = { - version = "0.8.27" + version = "0.8.28" source = "aquasecurity/aquasec" } } diff --git a/aquasec/utils.go b/aquasec/utils.go index 56f441a..e4f2d05 100644 --- a/aquasec/utils.go +++ b/aquasec/utils.go @@ -226,6 +226,8 @@ func isSaasEnv() bool { return true case consts.SaasAsia2Url: return true + case consts.SaaSAu2Url: + return true default: return false } diff --git a/client/client.go b/client/client.go index 07f56c9..6a54c50 100644 --- a/client/client.go +++ b/client/client.go @@ -80,6 +80,10 @@ func NewClient(url, user, password string, verifyTLS bool, caCertByte []byte) *C c.clientType = Saas c.tokenUrl = consts.SaasAsia2TokenUrl break + case consts.SaaSAu2Url: + c.clientType = Saas + c.tokenUrl = consts.SaasAu2TokenUrl + break case consts.SaasDevUrl: c.clientType = SaasDev c.tokenUrl = consts.SaasDevTokenUrl @@ -150,6 +154,9 @@ func (cli *Client) GetUSEAuthToken() (string, string, error) { case consts.SaasAsia2Url: provUrl = consts.SaasAsia2ProvUrl break + case consts.SaaSAu2Url: + provUrl = consts.SaasAu2ProvUrl + break case consts.SaasDevUrl: provUrl = consts.SaasDevProvUrl break diff --git a/consts/consts.go b/consts/consts.go index 15a947e..631128e 100644 --- a/consts/consts.go +++ b/consts/consts.go @@ -5,6 +5,7 @@ const ( SaasEu1Url = "https://eu-1.cloud.aquasec.com" SaasAsia1Url = "https://asia-1.cloud.aquasec.com" SaasAsia2Url = "https://asia-2.cloud.aquasec.com" + SaaSAu2Url = "https://ap-2.cloud.aquasec.com/" SaasDevUrl = "https://cloud-dev.aquasec.com" SaasDevTokenUrl = "https://stage.api.cloudsploit.com" SaasDevProvUrl = "https://prov-dev.cloud.aquasec.com" @@ -12,10 +13,12 @@ const ( SaasEu1TokenUrl = "https://eu-1.api.cloudsploit.com" SaasAsia1TokenUrl = "https://asia-1.api.cloudsploit.com" SaasAsia2TokenUrl = "https://asia-2.api.cloudsploit.com" + SaasAu2TokenUrl = "https://ap-2.api.cloudsploit.com" SaasProvUrl = "https://prov.cloud.aquasec.com" SaasEu1ProvUrl = "https://prov-eu-1.cloud.aquasec.com" SaasAsia1ProvUrl = "https://prov-asia-1.cloud.aquasec.com" SaasAsia2ProvUrl = "https://prov-asia-2.cloud.aquasec.com" + SaasAu2ProvUrl = "https://prov-ap-2.cloud.aquasec.com" SamlSettingsApiPath = "/api/v1/settings/SAMLSettings/SAMLSettings" OIDCSettingsApiPath = "/api/v1/settings/OIDCSettings/OIDCSettings" OpenIdSettingsApiPath = "/api/v1/settings/OIDCSettings/OpenIdSettings" diff --git a/docs/index.md b/docs/index.md index 40935f9..1bee4cd 100644 --- a/docs/index.md +++ b/docs/index.md @@ -21,7 +21,7 @@ Use the navigation to the left to read about the available resources and data so terraform { required_providers { aquasec = { - version = "0.8.27" + version = "0.8.28" source = "aquasecurity/aquasec" } } diff --git a/examples/data-sources/main.tf b/examples/data-sources/main.tf index d127c00..e17c59e 100644 --- a/examples/data-sources/main.tf +++ b/examples/data-sources/main.tf @@ -1,7 +1,7 @@ terraform { required_providers { aquasec = { - // version = "0.8.27" + // version = "0.8.28" source = "aquasecurity/aquasec" } } diff --git a/examples/provider/provider.tf b/examples/provider/provider.tf index cf316fb..bbba0c2 100644 --- a/examples/provider/provider.tf +++ b/examples/provider/provider.tf @@ -1,7 +1,7 @@ terraform { required_providers { aquasec = { - version = "0.8.27" + version = "0.8.28" source = "aquasecurity/aquasec" } } diff --git a/examples/resources/main.tf b/examples/resources/main.tf index a84ba60..41e3ade 100644 --- a/examples/resources/main.tf +++ b/examples/resources/main.tf @@ -1,7 +1,7 @@ terraform { required_providers { aquasec = { - // version = "0.8.27" + // version = "0.8.28" source = "aquasecurity/aquasec" } }