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

New resource: aws_imagebuilder_infrastracture_configuration #14347

Conversation

blckct
Copy link
Contributor

@blckct blckct commented Jul 26, 2020

Community Note

  • Please vote on this pull request by adding a 👍 reaction to the original pull request comment to help the community and maintainers prioritize this request
  • Please do not leave "+1" or other comments that do not add relevant new information or questions, they generate extra noise for pull request followers and do not help prioritize the request

New resource as part of image builder work, based on work by @Dogers

Part of #11084
Release note for CHANGELOG:

aws/aws_imagebuilder_infrastracture_configuration: New resource

Output from acceptance testing:

TF_ACC=1 go test ./aws -v -count 1 -parallel 20 -run=TestAccAWSImageBuilderInfrastructureConfiguration_tags -timeout 120m
=== RUN   TestAccAWSImageBuilderInfrastructureConfiguration_tags
=== PAUSE TestAccAWSImageBuilderInfrastructureConfiguration_tags
=== CONT  TestAccAWSImageBuilderInfrastructureConfiguration_tags
--- PASS: TestAccAWSImageBuilderInfrastructureConfiguration_tags (58.26s)
PASS
ok  	github.com/terraform-providers/terraform-provider-aws/aws	58.288s
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./aws -v -count 1 -parallel 20 -run=TestAccAWSImageBuilderInfrastructureConfiguration_advanced -timeout 120m
=== RUN   TestAccAWSImageBuilderInfrastructureConfiguration_advanced
=== PAUSE TestAccAWSImageBuilderInfrastructureConfiguration_advanced
=== CONT  TestAccAWSImageBuilderInfrastructureConfiguration_advanced
--- PASS: TestAccAWSImageBuilderInfrastructureConfiguration_advanced (39.63s)
PASS
ok  	github.com/terraform-providers/terraform-provider-aws/aws	39.678s
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./aws -v -count 1 -parallel 20 -run=TestAccAWSImageBuilderInfrastructureConfiguration_basic -timeout 120m
=== RUN   TestAccAWSImageBuilderInfrastructureConfiguration_basic
=== PAUSE TestAccAWSImageBuilderInfrastructureConfiguration_basic
=== CONT  TestAccAWSImageBuilderInfrastructureConfiguration_basic

--- PASS: TestAccAWSImageBuilderInfrastructureConfiguration_basic (33.87s)
PASS
ok  	github.com/terraform-providers/terraform-provider-aws/aws	33.973s

...

@blckct blckct requested a review from a team July 26, 2020 00:28
@ghost ghost added size/XL Managed by automation to categorize the size of a PR. needs-triage Waiting for first response or review from a maintainer. documentation Introduces or discusses updates to documentation. provider Pertains to the provider itself, rather than any interaction with AWS. service/imagebuilder Issues and PRs that pertain to the imagebuilder service. tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure. labels Jul 26, 2020
@Dogers Dogers mentioned this pull request Jul 27, 2020
6 tasks
@blckct blckct force-pushed the imagebuilder_infrastracture_configuration branch from cf173b8 to f7e8ae0 Compare July 27, 2020 16:55
@blckct blckct force-pushed the imagebuilder_infrastracture_configuration branch from f7e8ae0 to ade62ae Compare July 27, 2020 16:56
@blckct
Copy link
Contributor Author

blckct commented Jul 27, 2020

Squashed and rebased, run tests again:

TF_ACC=1 go test ./aws -v -count 1 -parallel 20 -run=TestAccAWSImageBuilderInfrastructureConfiguration_tags -timeout 120m
=== RUN   TestAccAWSImageBuilderInfrastructureConfiguration_tags
=== PAUSE TestAccAWSImageBuilderInfrastructureConfiguration_tags
=== CONT  TestAccAWSImageBuilderInfrastructureConfiguration_tags
--- PASS: TestAccAWSImageBuilderInfrastructureConfiguration_tags (40.69s)
PASS
ok  	github.com/terraform-providers/terraform-provider-aws/aws	40.728s
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./aws -v -count 1 -parallel 20 -run=TestAccAWSImageBuilderInfrastructureConfiguration_advanced -timeout 120m
=== RUN   TestAccAWSImageBuilderInfrastructureConfiguration_advanced
=== PAUSE TestAccAWSImageBuilderInfrastructureConfiguration_advanced
=== CONT  TestAccAWSImageBuilderInfrastructureConfiguration_advanced
--- PASS: TestAccAWSImageBuilderInfrastructureConfiguration_advanced (29.07s)
PASS
ok  	github.com/terraform-providers/terraform-provider-aws/aws	29.119s
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./aws -v -count 1 -parallel 20 -run=TestAccAWSImageBuilderInfrastructureConfiguration_basic -timeout 120m
=== RUN   TestAccAWSImageBuilderInfrastructureConfiguration_basic
=== PAUSE TestAccAWSImageBuilderInfrastructureConfiguration_basic
=== CONT  TestAccAWSImageBuilderInfrastructureConfiguration_basic
--- PASS: TestAccAWSImageBuilderInfrastructureConfiguration_basic (23.27s)
PASS
ok  	github.com/terraform-providers/terraform-provider-aws/aws	23.311s

@teamterraform
Copy link

Notification of Recent and Upcoming Changes to Contributions

Thank you for this contribution! There have been a few recent development changes that affect this pull request. We apologize for the inconvenience, especially if there have been long review delays up until now. Please note that this is automated message from an unmonitored account. See the FAQ for additional information on the maintainer team and review prioritization.

If you are unable to complete these updates, please leave a comment for the community and maintainers so someone can potentially continue the work. The maintainers will encourage other contributors to use the existing contribution as the base for additional changes as appropriate. Otherwise, contributions that do not receive updated code or comments from the original contributor may be closed in the future so the maintainers can focus on active items.

For the most up to date information about Terraform AWS Provider development, see the Contributing Guide. Additional technical debt changes can be tracked with the technical-debt label on issues.

As part of updating a pull request with these changes, the most current unit testing and linting will run. These may report issues that were not previously reported.

Terraform 0.12 Syntax

Reference: #8950
Reference: #14417

Version 3 and later of the Terraform AWS Provider, which all existing contributions would potentially be added, only supports Terraform 0.12 and later. Certain syntax elements of Terraform 0.11 and earlier show deprecation warnings during runs with Terraform 0.12. Documentation and test configurations, such as those including deprecated string interpolations (some_attribute = "${aws_service_thing.example.id}") should be updated to the newer syntax (some_attribute = aws_service_thing.example.id). Contribution testing will automatically fail on older syntax in the near future. Please see the referenced issues for additional information.

Action Required: Terraform Plugin SDK Version 2

Reference: #14551

The Terraform AWS Provider has been upgraded to the latest version of the Terraform Plugin SDK. Generally, most changes to contributions should only involve updating Go import paths in source code files. Please see the referenced issue for additional information.

Action Required: Removal of website/aws.erb File

Reference: #14712

Any changes to the website/aws.erb file are no longer necessary and should be removed from this contribution to prevent merge issues in the near future when the file is removed from the repository. Please see the referenced issue for additional information.

Upcoming Change of Git Branch Naming

Reference: #14292

Development environments will need their upstream Git branch updated from master to main in the near future. Please see the referenced issue for additional information and scheduling.

Upcoming Change of GitHub Organization

Reference: #14715

This repository will be migrating from https://github.com/terraform-providers/terraform-provider-aws to https://github.com/hashicorp/terraform-provider-aws. No practitioner or developer action is anticipated and most GitHub functionality will automatically redirect to the new location. Go import paths including terraform-providers can remain for now. Please see the referenced issue for additional information and scheduling.

@bflad bflad added new-resource Introduces a new resource. and removed needs-triage Waiting for first response or review from a maintainer. labels Nov 13, 2020
@bflad bflad self-assigned this Nov 13, 2020
bflad added a commit that referenced this pull request Nov 13, 2020
Reference: #11084
Reference: #13485
Reference: #14347

Changes:

```
* **New Data Source:** `aws_imagebuilder_infrastructure_configuration`
* **New Resource:** `aws_imagebuilder_infrastructure_configuration`
```

Output from acceptance testing in AWS Commercial:

```
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_basic (47.25s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_Description (56.76s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_disappears (34.25s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_InstanceProfileName (75.52s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_InstanceTypes (63.65s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_KeyPair (63.67s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_Logging_S3Logs_S3BucketName (82.86s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_Logging_S3Logs_S3KeyPrefix (76.12s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_ResourceTags (62.22s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_SecurityGroupIds (76.90s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_SnsTopicArn (69.00s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_SubnetId (76.21s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_Tags (74.09s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_TerminateInstanceOnFailure (62.45s)

--- PASS: TestAccAwsImageBuilderInfrastructureConfigurationDataSource_Arn (26.62s)
```

Output from acceptance testing in AWS GovCloud (US):

```
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_basic (51.08s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_Description (66.77s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_disappears (44.79s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_InstanceProfileName (76.02s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_InstanceTypes (71.91s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_KeyPair (73.11s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_Logging_S3Logs_S3BucketName (88.93s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_Logging_S3Logs_S3KeyPrefix (84.10s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_ResourceTags (71.55s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_SecurityGroupIds (81.06s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_SnsTopicArn (69.43s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_SubnetId (83.06s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_Tags (87.65s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_TerminateInstanceOnFailure (71.96s)

--- PASS: TestAccAwsImageBuilderInfrastructureConfigurationDataSource_Arn (33.51s)
```

Output from sweeper in AWS Commercial:

```
2020/11/13 14:24:06 [DEBUG] Running Sweepers for region (us-west-2):
2020/11/13 14:24:06 [DEBUG] Running Sweeper (aws_imagebuilder_infrastructure_configuration) in region (us-west-2)
2020/11/13 14:24:09 Sweeper Tests ran successfully:
  - aws_imagebuilder_infrastructure_configuration
2020/11/13 14:24:09 [DEBUG] Running Sweepers for region (us-east-1):
2020/11/13 14:24:09 [DEBUG] Running Sweeper (aws_imagebuilder_infrastructure_configuration) in region (us-east-1)
2020/11/13 14:24:11 Sweeper Tests ran successfully:
  - aws_imagebuilder_infrastructure_configuration
ok    github.com/terraform-providers/terraform-provider-aws/aws 7.692s
```
Output from sweeper in AWS GovCloud (US):

```
2020/11/13 14:24:10 [DEBUG] Running Sweepers for region (us-gov-west-1):
2020/11/13 14:24:10 [DEBUG] Running Sweeper (aws_imagebuilder_infrastructure_configuration) in region (us-gov-west-1)
2020/11/13 14:24:12 Sweeper Tests ran successfully:
  - aws_imagebuilder_infrastructure_configuration
ok    github.com/terraform-providers/terraform-provider-aws/aws 4.976s
```
bflad added a commit that referenced this pull request Nov 18, 2020
* Add aws_imagebuilder_infrastructureconfiguration

* Fix issue with infraconfig logging

* [#11084] Fix the imagebuilder resource, add test and docs

* New Resource: aws_imagebuilder_infrastructure_configuration

Reference: #11084
Reference: #13485
Reference: #14347

Changes:

```
* **New Data Source:** `aws_imagebuilder_infrastructure_configuration`
* **New Resource:** `aws_imagebuilder_infrastructure_configuration`
```

Output from acceptance testing in AWS Commercial:

```
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_basic (47.25s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_Description (56.76s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_disappears (34.25s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_InstanceProfileName (75.52s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_InstanceTypes (63.65s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_KeyPair (63.67s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_Logging_S3Logs_S3BucketName (82.86s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_Logging_S3Logs_S3KeyPrefix (76.12s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_ResourceTags (62.22s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_SecurityGroupIds (76.90s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_SnsTopicArn (69.00s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_SubnetId (76.21s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_Tags (74.09s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_TerminateInstanceOnFailure (62.45s)

--- PASS: TestAccAwsImageBuilderInfrastructureConfigurationDataSource_Arn (26.62s)
```

Output from acceptance testing in AWS GovCloud (US):

```
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_basic (51.08s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_Description (66.77s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_disappears (44.79s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_InstanceProfileName (76.02s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_InstanceTypes (71.91s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_KeyPair (73.11s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_Logging_S3Logs_S3BucketName (88.93s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_Logging_S3Logs_S3KeyPrefix (84.10s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_ResourceTags (71.55s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_SecurityGroupIds (81.06s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_SnsTopicArn (69.43s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_SubnetId (83.06s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_Tags (87.65s)
--- PASS: TestAccAwsImageBuilderInfrastructureConfiguration_TerminateInstanceOnFailure (71.96s)

--- PASS: TestAccAwsImageBuilderInfrastructureConfigurationDataSource_Arn (33.51s)
```

Output from sweeper in AWS Commercial:

```
2020/11/13 14:24:06 [DEBUG] Running Sweepers for region (us-west-2):
2020/11/13 14:24:06 [DEBUG] Running Sweeper (aws_imagebuilder_infrastructure_configuration) in region (us-west-2)
2020/11/13 14:24:09 Sweeper Tests ran successfully:
  - aws_imagebuilder_infrastructure_configuration
2020/11/13 14:24:09 [DEBUG] Running Sweepers for region (us-east-1):
2020/11/13 14:24:09 [DEBUG] Running Sweeper (aws_imagebuilder_infrastructure_configuration) in region (us-east-1)
2020/11/13 14:24:11 Sweeper Tests ran successfully:
  - aws_imagebuilder_infrastructure_configuration
ok    github.com/terraform-providers/terraform-provider-aws/aws 7.692s
```
Output from sweeper in AWS GovCloud (US):

```
2020/11/13 14:24:10 [DEBUG] Running Sweepers for region (us-gov-west-1):
2020/11/13 14:24:10 [DEBUG] Running Sweeper (aws_imagebuilder_infrastructure_configuration) in region (us-gov-west-1)
2020/11/13 14:24:12 Sweeper Tests ran successfully:
  - aws_imagebuilder_infrastructure_configuration
ok    github.com/terraform-providers/terraform-provider-aws/aws 4.976s
```

Co-authored-by: Dogers <Dogers@users.noreply.github.com>
Co-authored-by: Jakub Kania <jakubkania@blackcat.rocks>
@bflad
Copy link
Contributor

bflad commented Nov 18, 2020

GitHub may not be able to automatically pick up on this, but these commits were included with #16186, which was just merged.

@bflad bflad closed this Nov 18, 2020
@ghost
Copy link

ghost commented Dec 18, 2020

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.

If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. Thanks!

@ghost ghost locked as resolved and limited conversation to collaborators Dec 18, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
documentation Introduces or discusses updates to documentation. new-resource Introduces a new resource. provider Pertains to the provider itself, rather than any interaction with AWS. service/imagebuilder Issues and PRs that pertain to the imagebuilder service. size/XL Managed by automation to categorize the size of a PR. tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants