Skip to content

Conversation

@renovate
Copy link
Contributor

@renovate renovate bot commented Aug 16, 2025

This PR contains the following updates:

Package Type Update Change
cloudposse/vpc/aws (source) module minor 2.2.0 -> 2.3.0

Release Notes

cloudposse/terraform-aws-vpc (cloudposse/vpc/aws)

v2.3.0

Compare Source

Fixes "Error: no association of default Security Group (sg-XXX) with VPC Endpoint (vpce-YYY)" @​j4zzcat (#​158) This PR updates the `vpc-endpoints` module to prevent recurring no association of default Security Group (...) with VPC Endpoint (...) errors when managing Interface VPC Endpoints. See also https://github.com/cloudposse-terraform-components/aws-vpc/issues/49.

The issue occurred because AWS automatically attaches the default VPC security group to an Interface endpoint when no SGs are specified at creation. The module previously relied on replace_default_association to swap it out for the desired SG. This worked only on the first run - subsequent runs failed because the default SG was no longer attached.

Changes

  1. Attach first SG at creation time
    • Added security_group_ids to aws_vpc_endpoint.interface_endpoint with the first SG from var.interface_vpc_endpoints.
    • Prevents AWS from attaching the default SG and removes the need for replace_default_association.
  2. Limit SG associations to index > 0
    • Updated security_group_associations_list and security_group_associations_map locals to only include SGs beyond the first one.
    • Ensures Terraform doesn’t try to re-attach the already-attached first SG.
  3. Remove replace_default_association
    • Association resources now only attach additional SGs.
    • Eliminates fragile “replace default” logic that failed on repeated applies.

Benefits

  • Idempotent applies — no more failing after the first run.
  • Simpler logic — no special-case handling for the default SG.
  • Clean AWS state — the default SG is never attached in the first place.

Testing

  • Applied changes in a test environment with multiple endpoints and SGs.
  • Verified that:
    • First SG is attached at endpoint creation.
    • Additional SGs are attached via association resources.
    • No errors occur on repeated terraform apply runs.

Configuration

📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR was generated by Mend Renovate. View the repository job log.

@renovate renovate bot added the auto-update This PR was automatically generated label Aug 16, 2025
@renovate renovate bot requested review from a team as code owners August 16, 2025 22:47
@renovate renovate bot added the auto-update This PR was automatically generated label Aug 16, 2025
@renovate renovate bot requested review from Gowiem and johncblandii August 16, 2025 22:47
@mergify
Copy link
Contributor

mergify bot commented Aug 16, 2025

/terratest

@renovate renovate bot force-pushed the renovate/cloudposse-vpc-aws-2.x branch 2 times, most recently from 4f4938c to 56f3841 Compare September 14, 2025 10:00
@renovate renovate bot force-pushed the renovate/cloudposse-vpc-aws-2.x branch from 56f3841 to 6010c50 Compare October 1, 2025 04:23
@renovate renovate bot force-pushed the renovate/cloudposse-vpc-aws-2.x branch from 6010c50 to ce2db28 Compare October 14, 2025 18:03
@renovate renovate bot force-pushed the renovate/cloudposse-vpc-aws-2.x branch from ce2db28 to 8533fc0 Compare October 15, 2025 00:06
Copy link
Contributor

@oycyc oycyc left a comment

Choose a reason for hiding this comment

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

There is a newer version available. Closing.

@oycyc oycyc closed this Oct 25, 2025
@renovate
Copy link
Contributor Author

renovate bot commented Oct 25, 2025

Renovate Ignore Notification

Because you closed this PR without merging, Renovate will ignore this update (2.3.0). You will get a PR once a newer version is released. To ignore this dependency forever, add it to the ignoreDeps array of your Renovate config.

If you accidentally closed this PR, or if you changed your mind: rename this PR to get a fresh replacement PR.

@renovate renovate bot deleted the renovate/cloudposse-vpc-aws-2.x branch October 25, 2025 00:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

auto-update This PR was automatically generated

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants