-
Notifications
You must be signed in to change notification settings - Fork 9.3k
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
Add aws_dedicated_host for terraform-provider-aws #10817
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Mostly style/idiomatic Go stuff; feel free to address at your leisure. One question about a potential nil pointer situation that I'm not sure about-- if it's a non-issue then feel free to resolve.
Caveat: I'm not super familiar with this codebase do I didn't do a very thorough review of the logic (I'll leave that to the project maintainers and contributors) but nothing stands out to me. Good luck with the PR!
@rpomykala / @khyew - any update on this PR? we have a need for dedicated hosts and would love to have this make its way into the provider. let me know if there is anything left to resolve and we can pitch in to get it across the line |
Sorry for long time of inactivity, I have updated the module with MVP required to make it all work for anyone who needs it urgently. |
Excited to see this feature, can get rid of my boto/python pre tf build scripts :-) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
more comments:
- the
resources_aws_dedicated_host_test
needs to be rename todata_source_aws_dedicate_host_test
- add docs for data source
- add tests for the resource
@khyew / @DrFaust92 - anything we can do to help @rpomykala get this merged? they have updated several times but still no signs of when it will be ready to merge |
Notification of Recent and Upcoming Changes to ContributionsThank 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 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. Action Required: Terraform 0.12 SyntaxReference: #8950 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 ( Action Required: Terraform Plugin SDK Version 2Reference: #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 FileReference: #14712 Any changes to the Upcoming Change of Git Branch NamingReference: #14292 Development environments will need their upstream Git branch updated from Upcoming Change of GitHub OrganizationReference: #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 |
This feature will be handy in the context of the recent release of macOS support for EC2! |
We'd love to see this for ec2 macOS support as well! |
c9557f1
to
f190485
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 🚀.
Commercial
% make testacc TESTARGS='-run=TestAccAWSEc2Host_\|TestAccAWSEc2HostDataSource_'
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./aws -v -count 1 -parallel 20 -run=TestAccAWSEc2Host_\|TestAccAWSEc2HostDataSource_ -timeout 180m
=== RUN TestAccAWSEc2HostDataSource_basic
=== PAUSE TestAccAWSEc2HostDataSource_basic
=== RUN TestAccAWSEc2HostDataSource_Filter
=== PAUSE TestAccAWSEc2HostDataSource_Filter
=== RUN TestAccAWSEc2Host_basic
=== PAUSE TestAccAWSEc2Host_basic
=== RUN TestAccAWSEc2Host_disappears
=== PAUSE TestAccAWSEc2Host_disappears
=== RUN TestAccAWSEc2Host_InstanceFamily
=== PAUSE TestAccAWSEc2Host_InstanceFamily
=== RUN TestAccAWSEc2Host_Tags
=== PAUSE TestAccAWSEc2Host_Tags
=== CONT TestAccAWSEc2HostDataSource_basic
=== CONT TestAccAWSEc2Host_InstanceFamily
=== CONT TestAccAWSEc2Host_basic
=== CONT TestAccAWSEc2HostDataSource_Filter
=== CONT TestAccAWSEc2Host_disappears
=== CONT TestAccAWSEc2Host_Tags
--- PASS: TestAccAWSEc2Host_disappears (19.99s)
--- PASS: TestAccAWSEc2HostDataSource_basic (24.32s)
--- PASS: TestAccAWSEc2HostDataSource_Filter (24.35s)
--- PASS: TestAccAWSEc2Host_basic (26.18s)
--- PASS: TestAccAWSEc2Host_InstanceFamily (37.39s)
--- PASS: TestAccAWSEc2Host_Tags (49.11s)
PASS
ok github.com/terraform-providers/terraform-provider-aws/aws 52.966s
GovCloud
% make testacc TESTARGS='-run=TestAccAWSEc2Host_\|TestAccAWSEc2HostDataSource_'
==> Checking that code complies with gofmt requirements...
TF_ACC=1 go test ./aws -v -count 1 -parallel 20 -run=TestAccAWSEc2Host_\|TestAccAWSEc2HostDataSource_ -timeout 180m
=== RUN TestAccAWSEc2HostDataSource_basic
=== PAUSE TestAccAWSEc2HostDataSource_basic
=== RUN TestAccAWSEc2HostDataSource_Filter
=== PAUSE TestAccAWSEc2HostDataSource_Filter
=== RUN TestAccAWSEc2Host_basic
=== PAUSE TestAccAWSEc2Host_basic
=== RUN TestAccAWSEc2Host_disappears
=== PAUSE TestAccAWSEc2Host_disappears
=== RUN TestAccAWSEc2Host_InstanceFamily
=== PAUSE TestAccAWSEc2Host_InstanceFamily
=== RUN TestAccAWSEc2Host_Tags
=== PAUSE TestAccAWSEc2Host_Tags
=== CONT TestAccAWSEc2HostDataSource_basic
=== CONT TestAccAWSEc2Host_InstanceFamily
=== CONT TestAccAWSEc2Host_Tags
=== CONT TestAccAWSEc2Host_basic
=== CONT TestAccAWSEc2Host_disappears
=== CONT TestAccAWSEc2HostDataSource_Filter
=== CONT TestAccAWSEc2HostDataSource_basic
provider_test.go:1166: skipping test for aws-us-gov/us-gov-west-1: Error running apply: exit status 1
Error: error allocating EC2 Host: UnsupportedHostConfiguration: The requested configuration is currently not supported. Please check the documentation for supported configurations.
status code: 400, request id: e615d2d2-ee12-45fc-8329-744e3d386083
with aws_ec2_host.test,
on terraform_plugin_test.tf line 11, in resource "aws_ec2_host" "test":
11: resource "aws_ec2_host" "test" {
=== CONT TestAccAWSEc2Host_disappears
provider_test.go:1166: skipping test for aws-us-gov/us-gov-west-1: Error running apply: exit status 1
Error: error allocating EC2 Host: UnsupportedHostConfiguration: The requested configuration is currently not supported. Please check the documentation for supported configurations.
status code: 400, request id: b74fbd7e-fae7-45bb-bf83-4d90c7d896b6
with aws_ec2_host.test,
on terraform_plugin_test.tf line 11, in resource "aws_ec2_host" "test":
11: resource "aws_ec2_host" "test" {
=== CONT TestAccAWSEc2Host_Tags
provider_test.go:1166: skipping test for aws-us-gov/us-gov-west-1: Error running apply: exit status 1
Error: error allocating EC2 Host: UnsupportedHostConfiguration: The requested configuration is currently not supported. Please check the documentation for supported configurations.
status code: 400, request id: 04b7e281-e827-40e5-beeb-470525696ea9
with aws_ec2_host.test,
on terraform_plugin_test.tf line 11, in resource "aws_ec2_host" "test":
11: resource "aws_ec2_host" "test" {
=== CONT TestAccAWSEc2HostDataSource_Filter
provider_test.go:1166: skipping test for aws-us-gov/us-gov-west-1: Error running apply: exit status 1
Error: error allocating EC2 Host: UnsupportedHostConfiguration: The requested configuration is currently not supported. Please check the documentation for supported configurations.
status code: 400, request id: 66f9b95e-efa0-4673-b8d2-212065e7ec3a
with aws_ec2_host.test,
on terraform_plugin_test.tf line 11, in resource "aws_ec2_host" "test":
11: resource "aws_ec2_host" "test" {
=== CONT TestAccAWSEc2Host_basic
provider_test.go:1166: skipping test for aws-us-gov/us-gov-west-1: Error running apply: exit status 1
Error: error allocating EC2 Host: UnsupportedHostConfiguration: The requested configuration is currently not supported. Please check the documentation for supported configurations.
status code: 400, request id: 200aaaf1-7dfd-4ed5-8642-0918037a89cf
with aws_ec2_host.test,
on terraform_plugin_test.tf line 11, in resource "aws_ec2_host" "test":
11: resource "aws_ec2_host" "test" {
--- SKIP: TestAccAWSEc2Host_Tags (12.93s)
--- SKIP: TestAccAWSEc2Host_disappears (12.99s)
--- SKIP: TestAccAWSEc2HostDataSource_basic (13.08s)
--- SKIP: TestAccAWSEc2Host_basic (13.14s)
--- SKIP: TestAccAWSEc2HostDataSource_Filter (13.20s)
--- PASS: TestAccAWSEc2Host_InstanceFamily (42.58s)
PASS
ok github.com/terraform-providers/terraform-provider-aws/aws 47.515s
@rpomykala Thanks for the contribution 🎉 👏. I went ahead and renamed the resource to |
This functionality has been released in v3.61.0 of the Terraform AWS Provider. Please see the Terraform documentation on provider versioning or reach out if you need any assistance upgrading. For further feature requests or bug reports with this functionality, please create a new GitHub issue following the template. Thank you! |
I'm going to lock this pull request because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. |
Community Note
Closes #10752.
Release note for CHANGELOG:
Output from acceptance testing: