Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(apig): add new datasource to get list of signatures #4818

Merged
merged 1 commit into from
May 23, 2024

Conversation

wangyuancheng01
Copy link
Contributor

@wangyuancheng01 wangyuancheng01 commented May 15, 2024

What this PR does / why we need it:
add new datasource to get list of signatures.

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

Special notes for your reviewer:

Release note:


PR Checklist

  • Tests added/passed.
  • Documentation updated.
  • Schema updated.

Acceptance Steps Performed

make testacc TEST="./huaweicloud/services/acceptance/apig" TESTARGS="-run TestAccDataSourceSignatures_basic"
...
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./huaweicloud/services/acceptance/apig -v -run TestAccDataSourceSignatures_basic -timeout 360m -parallel 4
=== RUN   TestAccDataSourceSignatures_basic
=== PAUSE TestAccDataSourceSignatures_basic
=== CONT  TestAccDataSourceSignatures_basic
--- PASS: TestAccDataSourceSignatures_basic (549.12s)
PASS
ok      github.com/huaweicloud/terraform-provider-huaweicloud/huaweicloud/services/acceptance/apig      549.266s

variable "instance_id" {}
variable "signature_name" {}

data "huaweicloud_apig_api_associated_acl_policies" "test" {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
data "huaweicloud_apig_api_associated_acl_policies" "test" {
data "huaweicloud_apig_signatures" "test" {

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

signSecret := utils.Reverse(signKey)

return fmt.Sprintf(`
%s
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
%s
%s

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

@wangyuancheng01 wangyuancheng01 force-pushed the apig_sign branch 3 times, most recently from fcbb17f to 5f2c93e Compare May 21, 2024 00:57

* `bind_num` - The number of bound APIs.

* `created_at` - The creation time of the signature.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
* `created_at` - The creation time of the signature.
* `created_at` - The creation time of the signature, in RFC3339 format.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

@Lance52259
Copy link
Collaborator

/approve
/lgtm

@github-ci-robot github-ci-robot added LGTM /lgtm approved Indicates a PR has been approved by an approver from all required OWNERS files. labels May 23, 2024
Copy link
Collaborator

@github-ci-robot github-ci-robot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This PR has been approved by: @Lance52259

/approve
/lgtm

@github-ci-robot github-ci-robot merged commit c85f0ad into huaweicloud:master May 23, 2024
14 checks passed
@wangyuancheng01 wangyuancheng01 deleted the apig_sign branch May 23, 2024 06:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. feature LGTM /lgtm size/L
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants