-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Add new compute-network-firewall-policy-with-rules resource #11524
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 new compute-network-firewall-policy-with-rules resource #11524
Conversation
29fcf77
to
32b6bf7
Compare
32b6bf7
to
4c29d55
Compare
Hello! I am a robot. Tests will require approval from a repository maintainer to run. @NickElliot, a repository maintainer, has been assigned to review your changes. If you have not received review feedback within 2 business days, please leave a comment on this PR asking them to take a look. You can help make sure that review is quick by doing a self-review and by running impacted tests locally. |
Hi there, I'm the Modular magician. I've detected the following information about your changes: Diff reportYour PR generated some diffs in downstreams - here they are.
Missing test reportYour PR includes resource fields which are not covered by any test. Resource: resource "google_compute_network_firewall_policy_with_rules" "primary" {
rule {
rule_name = # value needed
security_profile_group = # value needed
target_service_accounts = # value needed
tls_inspect = # value needed
}
}
|
Tests analyticsTotal tests: 990 Click here to see the affected service packages
Action takenFound 2 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
|
|
Hi there, I'm the Modular magician. I've detected the following information about your changes: Diff reportYour PR generated some diffs in downstreams - here they are.
|
Tests analyticsTotal tests: 991 Click here to see the affected service packages
Action takenFound 4 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
|
Tests failed due to non-determinism or randomness when the VCR replayed the response after the HTTP request was made. Please fix these to complete your PR. If you believe these test failures to be incorrect or unrelated to your change, or if you have any questions, please raise the concern with your reviewer. |
Could I ask fro review? |
@NickElliot This PR has been waiting for review for 3 weekdays. Please take a look! Use the label |
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.
hi, a couple formatting changes needed
could you link me some of the public documentation on the resource?
mmv1/templates/terraform/constants/resource_compute_network_firewall_policy_with_rules.go.erb
Outdated
Show resolved
Hide resolved
mmv1/templates/terraform/decoders/resource_compute_network_firewall_policy_with_rules.go.erb
Outdated
Show resolved
Hide resolved
Fix formatting Co-authored-by: Nick Elliot <[email protected]>
Docs: For firewall policy there's a terraform resource (not possible to set rules): And the rules in firewall policy can be configured using: The new google_compute_network_firewall_policy_with_rules would allow a user to configure firewall policy with all rules (it was suggested by rileykarson to create a new resource to handle it). There are similar PRs for regional and org firewall policies: |
@NickElliot This PR has been waiting for review for 3 weekdays. Please take a look! Use the label |
Hi there, I'm the Modular magician. I've detected the following information about your changes: Diff reportYour PR generated some diffs in downstreams - here they are.
|
Tests analyticsTotal tests: 868 Click here to see the affected service packages
Action takenFound 2 affected test(s) by replaying old test recordings. Starting RECORDING based on the most recent commit. Click here to see the affected tests
|
Tests failed due to non-determinism or randomness when the VCR replayed the response after the HTTP request was made. Please fix these to complete your PR. If you believe these test failures to be incorrect or unrelated to your change, or if you have any questions, please raise the concern with your reviewer. |
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
…oudPlatform#11524) Co-authored-by: Nick Elliot <[email protected]>
…oudPlatform#11524) Co-authored-by: Nick Elliot <[email protected]>
…oudPlatform#11524) Co-authored-by: Nick Elliot <[email protected]>
…oudPlatform#11524) Co-authored-by: Nick Elliot <[email protected]>
@mihhalj I have experimented with the new resource a little bit, it isn't great. Adding a new rule between existing rules yields a plan which recreates all the rules following the new addition. The same happens when deleting a rule when multiple rules exist. |
joekohlsdorf Thanks for testing and You're right - using this resource when you update/remove/add even only one rule it results in updating all rules - the main goal for this resource is to be able to change many rules at once - it either succeeds and all the rules are updated or it fails and none of the rules are not updated - for example if one of the rule is invalid then the firewall policy won't be updated (there won't be a situation where valid rules are updated and invalid not). Compare it to the case when you use compute_network_firewall_policy_rule resources for your rules - valid rules will be configured and the invalid not. |
Add a new resource to allow updating all rules in network firewall policy at once.
Fixes
hashicorp/terraform-provider-google#19195
Release Note Template for Downstream PRs (will be copied)