Commit Graph

7980 Commits (795a2dc309c37e741738b3b1c92c266cbc62f93e)
 

Author SHA1 Message Date
ChengHao Yang 795a2dc309
Bump: OpenStack Cloud Controller Manager to v1.31.1 (#11738)
* Refactor: replace registry.k8s.io with kube_image_repo variable

Signed-off-by: ChengHao Yang <17496418+tico88612@users.noreply.github.com>

* Bump: OpenStack Cloud Controller Manager upgrade to v1.31.1

Signed-off-by: ChengHao Yang <17496418+tico88612@users.noreply.github.com>

* Refactor: remove occm image tag from sample inventory

Signed-off-by: ChengHao Yang <17496418+tico88612@users.noreply.github.com>

---------

Signed-off-by: ChengHao Yang <17496418+tico88612@users.noreply.github.com>
2024-11-25 13:38:56 +00:00
ChengHao Yang 3f45301919
Bump: Kubernetes default version v1.31.3 (#11737)
* Bump: Kubernetes default version set to v1.31.3

Signed-off-by: ChengHao Yang <17496418+tico88612@users.noreply.github.com>

* Docs: README.md update kubernetes version

Signed-off-by: ChengHao Yang <17496418+tico88612@users.noreply.github.com>

---------

Signed-off-by: ChengHao Yang <17496418+tico88612@users.noreply.github.com>
2024-11-25 09:14:57 +00:00
Bin Zhao d4b2f8c9e9
Update README.md to fix several doc links for OpenStack and vSphere (#11736)
Fix 3 broken links.
Two of them are because of https://github.com/kubernetes-sigs/kubespray/pull/11633
2024-11-25 09:10:56 +00:00
Max Gautier 2e145ffc12
Fix the format of the list of images extracted from kubeadm (#11741)
The download role expect 'groups' be a list, in order to properly filter
images.
2024-11-25 09:06:56 +00:00
Kay Yan 83a340baf1
Update rockylinux9 base image to 9.5 (#11744) 2024-11-25 09:00:57 +00:00
logicsys b8541962f3
Partial Cilium 1.16+ Support & Add vars for configuring cilium IP load balancer pools and bgp v1 & v2 apis (#11620)
* Add vars for configuring cilium IP load balancer pools and bgp peer policies

* Cilium 1.16+ Support - Add vars for configuring cilium bgpv2 api & handle cilium_kube_proxy_replacement unsupported values
2024-11-19 02:48:53 +00:00
dependabot[bot] e330ffa4ad
build(deps): bump ansible-lint from 24.9.2 to 24.10.0 (#11720)
Bumps [ansible-lint](https://github.com/ansible/ansible-lint) from 24.9.2 to 24.10.0.
- [Release notes](https://github.com/ansible/ansible-lint/releases)
- [Commits](https://github.com/ansible/ansible-lint/compare/v24.9.2...v24.10.0)

---
updated-dependencies:
- dependency-name: ansible-lint
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-11-18 17:58:57 +00:00
Max Gautier 6536ed41ac
Bump version of community.general (#11724)
We use the persistent option of modprobe, which was introduced in 7.0.0
2024-11-18 11:02:54 +00:00
Max Gautier badfb6ca34
Fix the pretty-printing of (core|nodelocal)dns (#11694)
When using
dns_upstream_forward_extra_opts:
  prefer_udp: "" # the option as no value so use empty string to just
                 # put the key

This is rendered in the dns configmap as ($ for end-of-line)

...
  prefer_udp $
...

Note the trailing space.
This triggers https://github.com/kubernetes/kubernetes/issues/36222,
which makes the configmap hardly readable when editing them manually or
simply putting them in a yaml file for inspection.

Trim the concatenation of option + value to get rid of any trailing
space.
2024-11-18 07:06:53 +00:00
ERIK 316e579543
fix task naming in bootstrap-os (#11714)
Signed-off-by: bo.jiang <bo.jiang@daocloud.io>
2024-11-17 17:22:53 +00:00
Javad e8bdd47ecc
Fix kubelet-csr-approver deployment failes if kube_network_plugin=cni(generic) (#11704)
* Make Helm's 'atomic' parameter configurable from role variables

* Configure Helm with 'atomic' and 'wait' set to false for generic CNI to prevent kubelet-csr-approver installation failures
2024-11-16 14:54:54 +00:00
Max Gautier c4b53ff01a
Include scripts and conf files in the ansible collection (#11707)
We use shell scripts and conf files in some roles (notably, certificates
provisioning), so we need to include them in order for the collection to
work when using the configurations depending on those roles.
2024-11-15 09:40:52 +00:00
Max Gautier 68718dcb6f
Stricter kubeadm validation (config and runtime checks) (#11710)
* kubeadm: do not ignore preflight errors blindly

The "ignoring all errors" seems to date back to the inception of the
kubeadm support (it was --skip-preflight-check before).

This can mask real errors and prevent users from seeing them.

Do not ignore any errors by default and make the set of ignored errors
configurable.

* download/kubeadm: remove redundant task

The mode is already set by the previous `copy` task.

* Validate kubeadm configs

This should help to fail early when we have invalid kubeadm configs (from
a kubespray bug or a misconfiguration).

* kubeadm-upgrade: remove unnecessary bool cast

* Convert kubeadm join discovery timeout to v1beta4 config

* CI: Ignore kubeadm:Mem errors on some setup.
2024-11-15 06:34:52 +00:00
Kubernetes Prow Robot 05e2b47db6
Merge pull request #11530 from VannTen/ci/cleanup_with_k8s_gc
[CI] Use Kubernetes GC to clean kubevirt VMs (packet-* jobs)
2024-11-14 10:49:15 +00:00
Max Gautier 47f67818b6
CI: (packet-ci) simplify role layout 2024-11-14 09:41:02 +01:00
Max Gautier 236a7486f4
CI: directly use ANSIBLE_VERBOSITY instead of tweaking command line
https://docs.ansible.com/ansible/latest/reference_appendices/config.html#envvar-ANSIBLE_VERBOSITY
2024-11-14 09:41:01 +01:00
Max Gautier b5464afa55
CI: workaround for upgrade test backward compatibility
The new CI does not define k8s_cluster group, so it relies on
kubernetes-sigs/kubespray#11559.

This does not work for upgrade testing (which use the previous release).
We can revert this commit after 2.27.0
2024-11-14 09:41:01 +01:00
Max Gautier ceb4b2fa7d
CI: use current tests/ directory for upgrade testing
We should not rollback our test setup during upgrade test.
The only reason to do that would be for incompatible changes in the test
inventory, and we already checkout master for those (${CI_JOB_NAME}.yml)

Also do some cleanup by removing unnecessary intermediary variables
2024-11-14 09:41:00 +01:00
Max Gautier ff4de880ae
CI: Replace kubevirt dynamic inventory with generated yaml
VirtualMachineInstance resources sometimes temporarily loose their
IP (at least as far as the kubevirt controllers can see).
See https://github.com/kubevirt/kubevirt/issues/12698 for the upstream
bug.

This does not seems to affect actual connection (if it did, our current
CI would not work).
However, our CI execute multiple playbooks, and in particular:
1. The provisioning playbook (which checks that the IPs have been
   provisioned by querying the K8S API)
2. Kubespray itself

If any of the VirtualMachineInstance looses its IP between after 1
checked for it, and before 2 starts, the dynamic inventory (which is
invoked when the playbook is launched by ansible-playbook) will not have
an ip for that host, and will try to use the name for ssh, which of
course will not work.

Instead, when we have a valid state during provisioning (all IPs
presents), use it to construct a static inventory which will be used for
the rest of the CI run.
2024-11-14 09:40:59 +01:00
Max Gautier 329ffd45f0
CI: use kubevirt.core dynamic inventory
This allows a single source of truth for the virtual machines in a
kubevirt ci-run.

`etcd_member_name` should be correctly handled in kubespray-defaults for
testing the recover cases.
2024-11-14 09:40:58 +01:00
Max Gautier 1a4567ac29
Remove deprecated key from kubeadmconfig/v1beta4 (#11709)
timeoutForControlPlane has been removed from v1beta4, instead remplaced
by https://kubernetes.io/docs/reference/config-api/kubeadm-config.v1beta4/#kubeadm-k8s-io-v1beta4-Timeouts

The default for the new value are close enough that there is no need to
override them.
2024-11-14 08:29:13 +00:00
Andreas Gravgaard Andersen 9f88f19e31
remove nameless extraArgs entry (#11703)
* remove nameless extraArgs entry

Signed-off-by: Andreas Gravgaard Andersen <andreasga22@gmail.com>

* fix template name

Signed-off-by: Andreas Gravgaard Andersen <andreasga22@gmail.com>

---------

Signed-off-by: Andreas Gravgaard Andersen <andreasga22@gmail.com>
2024-11-13 17:52:48 +00:00
Max Gautier a8e7238c9f
CI: make the ansible inventory a directory
Not constraining the inventory to .ini allows us to use dynamic
inventory, which is needed for simplifying kubevirt jobs inventory.

Also reduces the scope of the ANSIBLE_INVENTORY variable.
2024-11-13 17:32:52 +01:00
Max Gautier c46e5dc33a
CI: use VirtualMachineInstance for VMs
VMI in Kubevirt are the abstraction below VirtualMachine.

- We don't really need the extra abstraction of VirtualMachine objects
- Convert the waiting for VMs ip address to use kubernetes.core.k8s_info
  and no shell pipeline
2024-11-13 17:32:50 +01:00
Kay Yan 81a66cc73d
add ci for openeuler (#11689)
Signed-off-by: Kay Yan <kay.yan@daocloud.io>
2024-11-12 10:36:46 +00:00
dependabot[bot] 15af90db64
build(deps): bump ansible from 9.11.0 to 9.12.0 (#11705)
Bumps [ansible](https://github.com/ansible-community/ansible-build-data) from 9.11.0 to 9.12.0.
- [Changelog](https://github.com/ansible-community/ansible-build-data/blob/main/docs/release-process.md)
- [Commits](https://github.com/ansible-community/ansible-build-data/compare/9.11.0...9.12.0)

---
updated-dependencies:
- dependency-name: ansible
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-11-12 10:30:47 +00:00
Max Gautier 69201662df
Remove no_log in CI tests (#11702)
We always want to see the logs in the CI.
2024-11-11 03:54:44 +00:00
Max Gautier 06ae6cfe8a
Disable blank issue option in Github UI (#11701)
We're still getting bug reports circumventing the bug report template
and omitting informations.

Blank issue (aka, not using the form templates) can still be created
using the gh cli, the API, etc. This only disable the possibility in the
Web UI.
2024-11-11 03:44:46 +00:00
ChengHao Yang 76a5263ff3
Bump: pause container upgrade to 3.10 (#11695)
Signed-off-by: ChengHao Yang <17496418+tico88612@users.noreply.github.com>
2024-11-08 16:46:45 +00:00
Kubernetes Prow Robot 91a77e417c
Merge pull request #11674 from tico88612/feat/kubeadm-v1beta4
Feat: kubeadm v1beta4 support
2024-11-08 13:34:44 +00:00
Lee Spottiswood aa76e39f79
adds nodelocaldns_additional_configs to facilitate additional CoreDNS config options (#11657) 2024-11-08 02:46:44 +00:00
Max Gautier bf6687b032
preinstall: fix checking that excluded host are cached (#11693)
- Lookup was not returning a list, making the difference filter spit out
  garbage -> query always return a list
- hostvars is a dictionnary, so convert to list before selectattr and
  map back to only get keys
2024-11-07 10:27:33 +00:00
anders-elastisys d23753e9f7
Add support to use exisitng fips with terraform openstack (#11558) 2024-11-07 03:13:29 +00:00
Timothée Oliger 4e58413140
Add a new crio_root variable in order to store CRI-O data on something else than /var/lib (#11692) 2024-11-07 02:01:29 +00:00
Lihai Tu b7c1d68ea3
Fix coredns version constraint (#11691) 2024-11-06 10:29:29 +00:00
ChengHao Yang bf01b73578
Feat: kubeadm images download support v1beta4
Currently there is not much difference between the files, if there are more changes in the future,
please use different files to distinguish them (you can use the kubeadm_config_api_version variable)

Signed-off-by: ChengHao Yang <17496418+tico88612@users.noreply.github.com>
2024-11-05 23:35:58 +08:00
ChengHao Yang 1ec6711e95
Feat: add kubeadm-controlplane.yaml support v1beta4
Currently there is not much difference between the files, if there are more changes in the future,
please use different files to distinguish them (you can use the kubeadm_config_api_version variable)

Signed-off-by: ChengHao Yang <17496418+tico88612@users.noreply.github.com>
2024-11-05 23:35:57 +08:00
ChengHao Yang 53e5d8b392
Feat: add kubeadm-client.conf support v1beta4
Remove kubeadm api version condition.
Currently there is not much difference between the files, if there are more changes in the future,
please use different files to distinguish them (you can use the kubeadm_config_api_version variable)

Signed-off-by: ChengHao Yang <17496418+tico88612@users.noreply.github.com>
2024-11-05 23:35:57 +08:00
ChengHao Yang 5929935a19
Refactor: use kubeadm_config_api_version variable
I added the kubeadm_config_api_version variable in the previous commit,
and remove kubeadm api version condition.

Signed-off-by: ChengHao Yang <17496418+tico88612@users.noreply.github.com>
2024-11-05 23:35:57 +08:00
ChengHao Yang 9317e7ef25
Feat: add template kubeadm-config.yaml support v1beta4
v1beta4 has changed a lot in this file (e.g. ExtraArgs etc.), so it was implemented in separate files.

Signed-off-by: ChengHao Yang <17496418+tico88612@users.noreply.github.com>
2024-11-05 23:35:57 +08:00
ChengHao Yang 9b7d2857d1
Feat: add kubeadm_config_api_version default variable
If kube_version is v1.31 or higher, it will be v1beta4, otherwise it
will be v1beta3.

Signed-off-by: ChengHao Yang <17496418+tico88612@users.noreply.github.com>
2024-11-05 18:53:02 +08:00
Kubernetes Prow Robot a469c1c955
Merge pull request #11688 from VannTen/cleanup/preinstall_package_selection
Simplify package selection + fix openEuler package
2024-11-05 10:33:29 +00:00
Kubernetes Prow Robot 107c3cc6f4
Merge pull request #11633 from tico88612/feat/remove-in-tree-cloud-provider
Cleanup: remove in-tree cloud provider support
2024-11-05 09:13:30 +00:00
Kubernetes Prow Robot 25ca0acf73
Merge pull request #11667 from VannTen/ci-fix/kubelet_csr
Remove `shell` module usage from CI testcases
2024-11-05 08:41:29 +00:00
Max Gautier e1392c65b4
Fix openEuler packages
conntrack -> conntrack-tools
device-mapper-libs -> device-mapper
2024-11-05 09:36:40 +01:00
Max Gautier 8ff4ad2d8e
preinstall: simplify OS packages selection
Since a2019c1c2 (Add a JSON schema describing the packages install
structure, 2024-04-25), we use a custom structure to select which
packages should be installed on a particular host OS.

This has proven too rigid in practice, and the query is pretty
complicated.

Replace this by simply using an array of jinja conditions for the
packages, which should be easier to understand for everyone and more
flexible.

Also remove the associated schema and validation which are no longer
needed.
2024-11-05 09:35:50 +01:00
Max Gautier 0f0e24be0f
etcd: throttle restart for availability (#11677)
* etcd: throttle restart for availability

During upgrade, etcd member are restarted all at once.
This can impact the availability of the etcd cluster and subsequently of
the Kubernetes cluster.

Limit the concurrent restart so that the etcd cluster can keep quorum.

* Simplify etcd handlers
2024-11-05 06:11:29 +00:00
ChengHao Yang a070c72214
Refactor: simpify external_cloud_provider is defined
For this change, `external_cloud_provider` set default value to empty
string.

Signed-off-by: ChengHao Yang <17496418+tico88612@users.noreply.github.com>
2024-11-05 08:32:39 +08:00
ChengHao Yang 38cd05c503
Refactor: simpify cloud_provider is defined condition
For this change, `cloud_provider` change the default value to empty
string.

Signed-off-by: ChengHao Yang <17496418+tico88612@users.noreply.github.com>
2024-11-05 08:32:39 +08:00
ChengHao Yang c27cc33bd7
Refactor: var kube_override_hostname only reserve in kubespray-defaults
Signed-off-by: ChengHao Yang <17496418+tico88612@users.noreply.github.com>
2024-11-05 01:00:39 +08:00