Skip to content

Commit

Permalink
Merge pull request #1175 from axel7born/fix-ipv6-worker-subnet
Browse files Browse the repository at this point in the history
Set IPv4 CIDR to empty string for IPv6 only shoots.
  • Loading branch information
hebelsan authored Dec 20, 2024
2 parents 7b14537 + b945a87 commit 5a4c4d9
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion pkg/controller/infrastructure/infraflow/reconcile.go
Original file line number Diff line number Diff line change
Expand Up @@ -681,13 +681,17 @@ func (c *FlowContext) ensureZones(ctx context.Context) error {
tagsPublic[TagKeyRolePublicELB] = TagValueELB
tagsPrivate := c.commonTagsWithSuffix(helper.GetSuffixSubnetPrivate())
tagsPrivate[TagKeyRolePrivateELB] = TagValueELB
workersCIDR := zone.Workers
if !isIPv4(c.getIpFamilies()) {
workersCIDR = ""
}
desired = append(desired,
&awsclient.Subnet{
Tags: tagsWorkers,
VpcId: c.state.Get(IdentifierVPC),
AvailabilityZone: zone.Name,
AssignIpv6AddressOnCreation: ptr.To(isIPv6(c.getIpFamilies())),
CidrBlock: zone.Workers,
CidrBlock: workersCIDR,
Ipv6Native: ptr.To(!isIPv4(c.getIpFamilies())),
EnableResourceNameDnsAAAARecordOnLaunch: ptr.To(!isIPv4(c.getIpFamilies())),
EnableDns64: ptr.To(!isIPv4(c.getIpFamilies())),
Expand Down

0 comments on commit 5a4c4d9

Please sign in to comment.