Skip to content

Updates in the calico config and template to support disabling ipv4 pools during pure ipv6 deployment#13225

Open
AbhiiTen wants to merge 3 commits into
kubernetes-sigs:masterfrom
AbhiiTen:calico-ipv6-fix
Open

Updates in the calico config and template to support disabling ipv4 pools during pure ipv6 deployment#13225
AbhiiTen wants to merge 3 commits into
kubernetes-sigs:masterfrom
AbhiiTen:calico-ipv6-fix

Conversation

@AbhiiTen
Copy link
Copy Markdown

@AbhiiTen AbhiiTen commented May 3, 2026

What type of PR is this?
/kind bug
/kind feature

What this PR does / why we need it:
Currently, when attempting a pure IPv6 deployment, Calico still attempts to allocate IPv4 addresses and utilize IPv4 CIDR pools
This PR updates the Calico configurations to correctly handle pure IPv6 stacks by:

  1. Setting CALICO_IPV4POOL_CIDR to "none" in the node environment variables when IPv4 is disabled.
  2. Updating the IP assignment logic in calico-config.yml.j2 to explicitly set assign_ipv4 to "false" and assign_ipv6 to "true" during pure IPv6 deployments.

Which issue(s) this PR fixes:
Fixes #13157

Special notes for your reviewer:
Please double-check the Jinja2 logic for dual-stack vs single-stack assignments to ensure it doesn't break existing IPv4-only or Dual-Stack clusters.
Does this PR introduce a user-facing change?:

- Calico network plugin now correctly supports disabling IPv4 pools during pure IPv6 deployments.
   - Setting CALICO_IPV4POOL_CIDR to "none" in the node environment variables when IPv4 is disabled.
   - Updating the IP assignment logic in calico-config.yml.j2 to explicitly set assign_ipv4 to "false" and assign_ipv6 to "true" during pure IPv6 deployments.

…upport disabling ipv4 pools during pure ipv6 deployment

Signed-off-by: root <kanyahal.abhishek@gmail.com>
@k8s-ci-robot k8s-ci-robot added do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. kind/bug Categorizes issue or PR as related to a bug. do-not-merge/release-note-label-needed Indicates that a PR should not merge because it's missing one of the release note labels. kind/feature Categorizes issue or PR as related to a new feature. labels May 3, 2026
@linux-foundation-easycla
Copy link
Copy Markdown

linux-foundation-easycla Bot commented May 3, 2026

CLA Signed

The committers listed above are authorized under a signed CLA.

@k8s-ci-robot
Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: AbhiiTen
Once this PR has been reviewed and has the lgtm label, please assign ant31 for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot requested review from ErikJiang and mzaian May 3, 2026 09:17
@k8s-ci-robot
Copy link
Copy Markdown
Contributor

Welcome @AbhiiTen!

It looks like this is your first PR to kubernetes-sigs/kubespray 🎉. Please refer to our pull request process documentation to help your PR have a smooth ride to approval.

You will be prompted by a bot to use commands during the review process. Do not be afraid to follow the prompts! It is okay to experiment. Here is the bot commands documentation.

You can also check if kubernetes-sigs/kubespray has its own contribution guidelines.

You may want to refer to our testing guide if you run into trouble with your tests not passing.

If you are having difficulty getting your pull request seen, please follow the recommended escalation practices. Also, for tips and tricks in the contribution process you may want to read the Kubernetes contributor cheat sheet. We want to make sure your contribution gets all the attention it needs!

Thank you, and welcome to Kubernetes. 😃

@k8s-ci-robot k8s-ci-robot added cncf-cla: no Indicates the PR's author has not signed the CNCF CLA. size/S Denotes a PR that changes 10-29 lines, ignoring generated files. needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels May 3, 2026
@k8s-ci-robot
Copy link
Copy Markdown
Contributor

Hi @AbhiiTen. Thanks for your PR.

I'm waiting for a kubernetes-sigs member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work.

Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@k8s-ci-robot k8s-ci-robot added cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. and removed cncf-cla: no Indicates the PR's author has not signed the CNCF CLA. labels May 3, 2026
@AbhiiTen AbhiiTen marked this pull request as ready for review May 3, 2026 09:38
@k8s-ci-robot k8s-ci-robot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label May 3, 2026
@k8s-ci-robot k8s-ci-robot requested review from VannTen and tico88612 May 3, 2026 09:38
Comment thread roles/network_plugin/calico/templates/calico-config.yml.j2 Outdated
@guoard
Copy link
Copy Markdown
Contributor

guoard commented May 4, 2026

/ok-to-test

@k8s-ci-robot k8s-ci-robot added ok-to-test Indicates a non-member PR verified by an org member that is safe to test. and removed needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels May 4, 2026
@AbhiiTen AbhiiTen requested a review from guoard May 4, 2026 14:12
@guoard
Copy link
Copy Markdown
Contributor

guoard commented May 4, 2026

/retest-failed

Comment thread roles/network_plugin/calico/templates/calico-node.yml.j2 Outdated
Comment thread roles/network_plugin/calico/templates/calico-node.yml.j2 Outdated
@AbhiiTen AbhiiTen requested a review from guoard May 4, 2026 15:20
@guoard
Copy link
Copy Markdown
Contributor

guoard commented May 5, 2026

/retest-failed

@guoard
Copy link
Copy Markdown
Contributor

guoard commented May 5, 2026

I don't know why status of that job didn't reported! but it was successful.

@guoard
Copy link
Copy Markdown
Contributor

guoard commented May 5, 2026

/retest-failed

@guoard
Copy link
Copy Markdown
Contributor

guoard commented May 6, 2026

/lgtm

@k8s-ci-robot k8s-ci-robot added lgtm "Looks good to me", indicates that a PR is ready to be merged. release-note Denotes a PR that will be considered when it comes time to generate release notes. and removed do-not-merge/release-note-label-needed Indicates that a PR should not merge because it's missing one of the release note labels. labels May 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. kind/bug Categorizes issue or PR as related to a bug. kind/feature Categorizes issue or PR as related to a new feature. lgtm "Looks good to me", indicates that a PR is ready to be merged. ok-to-test Indicates a non-member PR verified by an org member that is safe to test. release-note Denotes a PR that will be considered when it comes time to generate release notes. size/S Denotes a PR that changes 10-29 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Disable default IPv4 IPPool creation when ipv4_stack=false in pure IPv6 deployments (Calico) and ip assignment to the PODs

3 participants