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

[UX2.0] Transport IPv4 ACL apply doesn't work properly when only list elements are present in match_entries #381

Open
tzarski0 opened this issue Dec 9, 2024 · 0 comments

Comments

@tzarski0
Copy link
Collaborator

tzarski0 commented Dec 9, 2024

When you configure the following resource:

resource "sdwan_transport_feature_profile" "transport_profile_test" {
  name        = "transport_profile_test"
  description = ""
}

resource "sdwan_transport_ipv4_acl_feature" "transport_ipv4_acl_feature" {
  default_action     = "accept"
  description        = "control vpn 0 outbound traffic"
  feature_profile_id = sdwan_transport_feature_profile.transport_profile_test.id
  name               = "vpn0_acl_out"
  sequences = [
    {
      base_action = "accept"
      match_entries = [
        {
          dscps = [
            0,
            1
          ]
        },
      ]
      sequence_id   = 1
      sequence_name = "acl"
    },
  ]
}

The first TF apply work correctly, but 2nd terraform apply shows diff although nothing changes:

  # sdwan_transport_ipv4_acl_feature.transport_ipv4_acl_feature will be updated in-place
  ~ resource "sdwan_transport_ipv4_acl_feature" "transport_ipv4_acl_feature" {
        id                 = "cd760664-34a2-47a8-b309-3d0cc02f32c6"
        name               = "vpn0_acl_out"
      ~ sequences          = [
          ~ {
              ~ match_entries = [
                  ~ {
                      + dscps = [
                          + 0,
                          + 1,
                        ]
                    },
                ]
                # (3 unchanged attributes hidden)
            },
        ]
      ~ version            = 2 -> (known after apply)
        # (3 unchanged attributes hidden)
    }

Same issue happens if you configure any other set/list parameter like protocols etc. The fix we do here should work also for transport ipv6 acl and service ipv4/ipv6 acl.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant