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 azurerm_network_manager_scope_connection #19610

Merged

Conversation

teowa
Copy link
Contributor

@teowa teowa commented Dec 8, 2022

Notes:

Test:

TF_ACC=1 go test -v ./internal/services/network -test.run=TestAccNetworkManager -timeout 1440m -ldflags="-X=github.com/hashicorp/terraform-provider-azurerm/version.ProviderVersion=acc"
=== RUN   TestAccNetworkManager
=== RUN   TestAccNetworkManager/Manager
=== RUN   TestAccNetworkManager/Manager/requiresImport
=== RUN   TestAccNetworkManager/Manager/basic
=== RUN   TestAccNetworkManager/Manager/complete
=== RUN   TestAccNetworkManager/Manager/update
=== RUN   TestAccNetworkManager/ScopeConnection
=== RUN   TestAccNetworkManager/ScopeConnection/basic
=== RUN   TestAccNetworkManager/ScopeConnection/complete
=== RUN   TestAccNetworkManager/ScopeConnection/update
=== RUN   TestAccNetworkManager/ScopeConnection/requiresImport
--- PASS: TestAccNetworkManager (1904.83s)
    --- PASS: TestAccNetworkManager/Manager (988.38s)
        --- PASS: TestAccNetworkManager/Manager/requiresImport (242.18s)
        --- PASS: TestAccNetworkManager/Manager/basic (147.75s)
        --- PASS: TestAccNetworkManager/Manager/complete (157.65s)
        --- PASS: TestAccNetworkManager/Manager/update (440.80s)
    --- PASS: TestAccNetworkManager/ScopeConnection (916.45s)
        --- PASS: TestAccNetworkManager/ScopeConnection/basic (221.58s)
        --- PASS: TestAccNetworkManager/ScopeConnection/complete (169.06s)
        --- PASS: TestAccNetworkManager/ScopeConnection/update (282.09s)
        --- PASS: TestAccNetworkManager/ScopeConnection/requiresImport (243.71s)
PASS
ok      github.com/hashicorp/terraform-provider-azurerm/internal/services/network       1906.038s

Copy link
Collaborator

@katbyte katbyte left a comment

Choose a reason for hiding this comment

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

test failures:

 Error: creating Network Manager: (Name "acctest-networkmanager-221211222359842005" / Resource Group "acctestRG-nm-221211222359842005"): network.ManagersClient#CreateOrUpdate: Failure responding to request: StatusCode=400 -- Original Error: autorest/azure: Service returned an error. Status=400 Code="BadRequest" Message="Cannot have two Network Managers applied to the same object overlapping scope accesses. Scope id: /subscriptions/*******. Network Manager Id: /subscriptions/*******/resourceGroups/acctestRG-nm-221211222359842005/providers/Microsoft.Network/networkManagers/acctest-networkmanager-221211222359842005. Overlapping accesses: SecurityAdmin"

@teowa
Copy link
Contributor Author

teowa commented Dec 12, 2022

#19593 (comment)

Comment on lines 58 to 62
"resource_id": {
Type: pluginsdk.TypeString,
Required: true,
ValidateFunc: validation.StringIsNotEmpty,
},
Copy link
Contributor

Choose a reason for hiding this comment

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

we don't expose resource_id - what is this, a scope?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

modifies it to target_scope_id, it should be either Subscription ID or Management Group ID.

@teowa
Copy link
Contributor Author

teowa commented Dec 19, 2022

Provisioning two Network Manager using one subscription as scope leads to an error, to avoid test failure, temporary close this PR.

Please review #19593 first.

@teowa teowa closed this Dec 19, 2022
…m into network_manager_scope_connection_resource
…m:teowa/terraform-provider-azurerm into network_manager_scope_connection_resource
@teowa teowa reopened this Jan 13, 2023
@teowa
Copy link
Contributor Author

teowa commented Jan 15, 2023

image

Copy link
Collaborator

@katbyte katbyte left a comment

Choose a reason for hiding this comment

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

LGTM 🌵

@katbyte katbyte merged commit 5d4775e into hashicorp:main Jan 17, 2023
@github-actions github-actions bot added this to the v3.40.0 milestone Jan 17, 2023
katbyte added a commit that referenced this pull request Jan 17, 2023
@github-actions
Copy link

This functionality has been released in v3.40.0 of the Terraform 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!

@github-actions
Copy link

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 contributions.
If you have found a problem that seems related to this change, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Feb 20, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants