Skip to content

feat: Add cilium_install_extra_args #12262

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

tmurakam
Copy link
Contributor

@tmurakam tmurakam commented May 27, 2025

What type of PR is this?
/kind feature

What this PR does / why we need it:
Add cilium_install_extra_args variable for cilium install command.

This enables to use such as --chart-directory or --repository option to enable offline installation.

Which issue(s) this PR fixes:
Fixes #

Special notes for your reviewer:

Does this PR introduce a user-facing change?:

Add cilium_install_extra_args variable

@k8s-ci-robot
Copy link
Contributor

Skipping CI for Draft Pull Request.
If you want CI signal for your change, please convert it to an actual PR.
You can still manually trigger a test run with /test all

@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. release-note Denotes a PR that will be considered when it comes time to generate release notes. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. kind/feature Categorizes issue or PR as related to a new feature. labels May 27, 2025
@k8s-ci-robot k8s-ci-robot requested review from tico88612 and yankay May 27, 2025 05:16
@k8s-ci-robot k8s-ci-robot added the size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. label May 27, 2025
@tmurakam
Copy link
Contributor Author

tmurakam commented May 27, 2025

@tico88612
Could you check this?
This is needed for offline installation, because without --chart-directory option, cilium install pulls the chart from the Internet.

@tmurakam tmurakam marked this pull request as ready for review May 27, 2025 05:17
@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 27, 2025
@tmurakam
Copy link
Contributor Author

/ok-to-test

@k8s-ci-robot k8s-ci-robot added the ok-to-test Indicates a non-member PR verified by an org member that is safe to test. label May 27, 2025
Copy link
Contributor

@cyclinder cyclinder left a comment

Choose a reason for hiding this comment

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

thanks

@michelaldaher
Copy link

Hello,

I have found also that whenever we relaunch the cluster.yml playbook the second time is failing as cillium was already installed, can we replace it with upgrade ? but i did not find any flag --install to add to it. this is the error

TASK [network_plugin/cilium : Cilium | Install] *************************************************************************************************************************************************************************************
fatal: [yuv-offline-m]: FAILED! => {"changed": true, "cmd": ["/usr/local/bin/cilium", "install", "--version", "1.17.3", "--chart-directory", "/etc/kubernetes/cilium", "-f", "/etc/kubernetes/cilium-values.yaml"], "delta": "0:00:00.129057", "end": "2025-05-27 12:24:35.385909", "msg": "non-zero return code", "rc": 1, "start": "2025-05-27 12:24:35.256852", "stderr": "\nError: Unable to install Cilium: cannot re-use a name that is still in use", "stderr_lines": ["", "Error: Unable to install Cilium: cannot re-use a name that is still in use"], "stdout": "ℹ️ Using Cilium version 1.17.3\nℹ️ Using cluster name "default"\n🔮 Auto-detected kube-proxy has not been installed\nℹ️ Cilium will fully replace all functionalities of kube-proxy", "stdout_lines": ["ℹ️ Using Cilium version 1.17.3", "ℹ️ Using cluster name "default"", "🔮 Auto-detected kube-proxy has not been installed", "ℹ️ Cilium will fully replace all functionalities of kube-proxy"]}

NO MORE HOSTS LEFT ******************************************************************************************************************************************************************************************************************

PLAY RECAP **************************************************************************************************************************************************************************************************************************
test-m : ok=531 changed=13 unreachable=0 failed=1 skipped=619 rescued=0 ignored=2
test-w : ok=404 changed=8 unreachable=0 failed=0 skipped=460 rescued=0 ignored=2

i had also a problem with a missing image for cilium-operator-generic that I had to re-push manually

@tico88612
Copy link
Member

tico88612 commented May 27, 2025

This change is even better, but I'm trying to think of a more suitable name for it.

@michelaldaher off-topic with this PR, and this is a known issue. (BTW, cilium cli not support upgrade --install command) Could you try #12254 and report there? Thanks

Copy link
Member

@tico88612 tico88612 left a comment

Choose a reason for hiding this comment

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

I have some ideas, what do you think about cilium_install_args? I found that the arguments for cilium install and cilium upgrade are little different.

@tmurakam
Copy link
Contributor Author

tmurakam commented May 30, 2025

@tico88612
I'm a little concerned that the variable doesn't include --version and -f options, but overall I agree.
I will update this PR.

@tmurakam tmurakam force-pushed the feature/cilium-opts branch from a3f456f to 6063a05 Compare May 30, 2025 02:41
@tmurakam tmurakam changed the title feat: Add cilium_additional_install_options feat: Add cilium_install_args May 30, 2025
@tico88612
Copy link
Member

Oh, if this is a little confusing, what about cilium_install_extra_flags?
This will not conflict with any existing Kubernetes naming conventions.

image

@tmurakam tmurakam changed the title feat: Add cilium_install_args feat: Add cilium_install_extra_args May 30, 2025
@tmurakam tmurakam force-pushed the feature/cilium-opts branch from 6063a05 to b57482c Compare May 30, 2025 02:56
@tmurakam
Copy link
Contributor Author

tmurakam commented May 30, 2025

Ok, I updated the PR and title/description.

@tico88612 tico88612 added this to the 2.29 milestone Jun 5, 2025
@k8s-ci-robot k8s-ci-robot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Jun 20, 2025
Enable to use --chart-directory options etc for offline installation
@tmurakam tmurakam force-pushed the feature/cilium-opts branch from b57482c to 91389d8 Compare June 23, 2025 11:08
@k8s-ci-robot k8s-ci-robot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Jun 23, 2025
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

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

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

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

Copy link
Member

@tico88612 tico88612 left a comment

Choose a reason for hiding this comment

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

Little comment.

cilium_install_extra_flags would be better, as args could be confused with the pod's args.

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/feature Categorizes issue or PR as related to a new feature. 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/XS Denotes a PR that changes 0-9 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants