-
Notifications
You must be signed in to change notification settings - Fork 84
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 VPC attachment resource #1464
Conversation
--- PASS: TestAccResourceNsxtVpc_basic (72.41s) |
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
nsxt/provider.go
Outdated
"nsxt_vpc_dhcp_v4_static_binding": resourceNsxtVpcSubnetDhcpV4StaticBindingConfig(), | ||
"nsxt_vpc_attachment": resourceNsxtVpcAttachment(), | ||
}, | ||
|
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.
I'd suggest this be the first in the lists of nsxt_vpc_*
items (as well as ensure all listed resources and data sources are listed alphabetically.)
nsxt/resource_nsxt_vpc_attachment.go
Outdated
|
||
id := d.Id() | ||
if id == "" { | ||
return fmt.Errorf("Error obtaining VpcAttachment ID") |
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.
return fmt.Errorf("Error obtaining VpcAttachment ID") | |
return fmt.Errorf("error obtaining VpcAttachment ID") |
nsxt/resource_nsxt_vpc_attachment.go
Outdated
|
||
id := d.Id() | ||
if id == "" { | ||
return fmt.Errorf("Error obtaining VpcAttachment ID") |
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.
return fmt.Errorf("Error obtaining VpcAttachment ID") | |
return fmt.Errorf("error obtaining VpcAttachment ID") |
nsxt/resource_nsxt_vpc_attachment.go
Outdated
func resourceNsxtVpcAttachmentDelete(d *schema.ResourceData, m interface{}) error { | ||
id := d.Id() | ||
if id == "" { | ||
return fmt.Errorf("Error obtaining VpcAttachment ID") |
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.
return fmt.Errorf("Error obtaining VpcAttachment ID") | |
return fmt.Errorf("error obtaining VpcAttachment ID") |
This is the new way of attaching connectivity profile to vpc, hence the profile attribute is also removed from vpc resource Signed-off-by: Anna Khmelnitsky <[email protected]>
8aab5af
to
066ad49
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!
This is the new way of attaching connectivity profile to vpc, hence the profile attribute is also removed from vpc resource