Skip to content

Fix: apiVersion Cilium template#12966

Closed
uchiha-vivek wants to merge 2 commits into
kubernetes-sigs:masterfrom
uchiha-vivek:fix/12819-cilium-bgp-cluster-config-update
Closed

Fix: apiVersion Cilium template#12966
uchiha-vivek wants to merge 2 commits into
kubernetes-sigs:masterfrom
uchiha-vivek:fix/12819-cilium-bgp-cluster-config-update

Conversation

@uchiha-vivek
Copy link
Copy Markdown
Contributor

What type of PR is this?

/kind bug

What this PR does / why we need it:
uses stable cilium.io/v2 API for Cilium BGP v2 templates
Cilium BGP v2 APIs (CiliumBGPClusterConfig, CiliumBGPPeerConfig, CiliumBGPNodeConfigOverride, CiliumBGPAdvertisement) graduated to the stable cilium.io/v2 API in Cilium v1.16+.
Using the alpha API results in deprecation warnings on newer Cilium versions.

Testes the updated cilium-bgp-cluster-config.yml.j2 template locally using Ansible and validated the manifest with yaml.safe_load

ansible-tamplate-testing

Which issue(s) this PR fixes:

Fixes #12819

Special notes for your reviewer:
This is something to similar to issue #12843 and I have raised one pr for that specific fix #12952

Does this PR introduce a user-facing change?:

This Pull Request fixes user facing YAML rendering issues in the Cilium BGP advertisement template and updates it to use the stable v2 API. The change ensures valid manifests are generated for configurations with nested selectors and removes deprecation warnings on newer Cilium versions. No breaking changes are introduced.

…lium

Signed-off-by: uchiha-vivek <vs160125@gmail.com>
@k8s-ci-robot k8s-ci-robot added the release-note Denotes a PR that will be considered when it comes time to generate release notes. label Feb 5, 2026
@k8s-ci-robot
Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: uchiha-vivek
Once this PR has been reviewed and has the lgtm label, please assign tico88612 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 added size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels Feb 5, 2026
@k8s-ci-robot
Copy link
Copy Markdown
Contributor

Hi @uchiha-vivek. 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 the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label Feb 5, 2026
@uchiha-vivek
Copy link
Copy Markdown
Contributor Author

https://docs.cilium.io/en/stable/network/bgp-control-plane/bgp-control-plane-configuration/#bgp-cluster-configuration

I have taken the above link as reference

CiliumBGPClusterConfig

Their official docs

apiVersion: cilium.io/v2
kind: CiliumBGPClusterConfig
metadata:
  name: cilium-bgp
spec:
  nodeSelector:
    matchLabels:
      rack: rack0
  bgpInstances:
  - name: "instance-65000"
    localASN: 65000
    localPort: 179
    peers:
    - name: "peer-65000-tor1"
      peerASN: 65000
      peerAddress: fd00:10:0:0::1
      peerConfigRef:
        name: "cilium-peer"
    - name: "peer-65000-tor2"
      peerASN: 65000
      peerAddress: fd00:11:0:0::1
      peerConfigRef:
        name: "cilium-peer"

We can check the api version clearly

@tico88612
Copy link
Copy Markdown
Member

You can consider to migrate to #12952.

@uchiha-vivek
Copy link
Copy Markdown
Contributor Author

Member

Yes sir

All the previous changes for the pull request (kubernetes-sigs#12952) has been included within kubernetes-sigs#12966.
@k8s-ci-robot k8s-ci-robot added size/S Denotes a PR that changes 10-29 lines, ignoring generated files. and removed size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. labels Feb 9, 2026
@uchiha-vivek
Copy link
Copy Markdown
Contributor Author

You can consider to migrate to #12952.

@tico88612 Sir
I have migrated the changes for #12952 into #12966

@tico88612
Copy link
Copy Markdown
Member

/retitle Fix: apiVersion Cilium template
/ok-to-test

@k8s-ci-robot k8s-ci-robot changed the title fixed : (related to #12819) - updated apiVersion of cilium Fix: apiVersion Cilium template Feb 10, 2026
@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 Feb 10, 2026
{% endif %}
spec:
{{ cilium_bgp_advertisement.spec | to_yaml | indent(4) }}
{{ cilium_bgp_advertisement.spec | to_yaml | indent(2) }}
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Wondering why this part needs to be changed?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Honestly indent(2) and indent(4) both works. It's not a significant change. I was just following Jinja Template Documentation

@tico88612 Sir i can safely revert it back.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

If you want to change it, please make your commit messages clearer, and the same goes for everything else.

@tico88612
Copy link
Copy Markdown
Member

Superseded by #13095

/close

@k8s-ci-robot
Copy link
Copy Markdown
Contributor

@tico88612: Closed this PR.

Details

In response to this:

Superseded by #13095

/close

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
Copy link
Copy Markdown
Contributor

PR needs rebase.

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 the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Mar 14, 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. needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. 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.

CiliumBGPClusterConfig update

3 participants