Compare commits

...

4 Commits

Author SHA1 Message Date
Kay Yan
cd16ac7e47 Merge pull request #11722 from k8s-infra-cherrypick-robot/cherry-pick-11694-to-release-2.24
[release-2.24] Fix pretty-printing of coredns and nodelocaldns configmaps
2024-11-19 09:59:45 +08:00
Max Gautier
145a7942e5 Fix the pretty-printing of (core|nodelocal)dns
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:08:06 +00:00
k8s-infra-cherrypick-robot
c6f7597533 Always copy cert generation scripts to first etcd (#11614)
If we don't, existing installation would not pick up fix to that script,
such as dc33a1971d.

Co-authored-by: Max Gautier <mg@max.gautier.name>
2024-10-12 03:36:20 +01:00
Kay Yan
31bc45bdd0 cleanup-for-2.24.3 (#11551) 2024-09-18 11:56:44 +01:00
5 changed files with 12 additions and 7 deletions

View File

@@ -75,8 +75,8 @@ You will then need to use [bind mounts](https://docs.docker.com/storage/bind-mou
to access the inventory and SSH key in the container, like this:
```ShellSession
git checkout v2.24.2
docker pull quay.io/kubespray/kubespray:v2.24.2
git checkout v2.24.3
docker pull quay.io/kubespray/kubespray:v2.24.3
docker run --rm -it --mount type=bind,source="$(pwd)"/inventory/sample,dst=/inventory \
--mount type=bind,source="${HOME}"/.ssh/id_rsa,dst=/root/.ssh/id_rsa \
quay.io/kubespray/kubespray:v2.23.2 bash

View File

@@ -2,7 +2,7 @@
namespace: kubernetes_sigs
description: Deploy a production ready Kubernetes cluster
name: kubespray
version: 2.24.3
version: 2.24.4
readme: README.md
authors:
- luksi1

View File

@@ -35,7 +35,6 @@
mode: 0700
run_once: yes
when:
- gen_certs | default(false)
- inventory_hostname == groups['etcd'][0]
- name: Gen_certs | run cert generation script for etcd and kube control plane nodes

View File

@@ -70,7 +70,9 @@ data:
max_concurrent 1000
{% if dns_upstream_forward_extra_opts is defined %}
{% for optname, optvalue in dns_upstream_forward_extra_opts.items() %}
{{ optname }} {{ optvalue }}
{{ (optname ~ ' ' ~ optvalue) | trim }}
{# do not add a trailing space when optvalue == ''
workaround for: https://github.com/kubernetes/kubernetes/issues/36222 #}
{% endfor %}
{% endif %}
}

View File

@@ -82,7 +82,9 @@ data:
bind {{ nodelocaldns_ip }}
forward . {{ upstreamForwardTarget }}{% if dns_upstream_forward_extra_opts is defined %} {
{% for optname, optvalue in dns_upstream_forward_extra_opts.items() %}
{{ optname }} {{ optvalue }}
{{ (optname ~ ' ' ~ optvalue) | trim }}
{# do not add a trailing space when optvalue == ''
workaround for: https://github.com/kubernetes/kubernetes/issues/36222 #}
{% endfor %}
}{% endif %}
@@ -164,7 +166,9 @@ data:
bind {{ nodelocaldns_ip }}
forward . {{ upstreamForwardTarget }}{% if dns_upstream_forward_extra_opts is defined %} {
{% for optname, optvalue in dns_upstream_forward_extra_opts.items() %}
{{ optname }} {{ optvalue }}
{{ (optname ~ ' ' ~ optvalue) | trim }}
{# do not add a trailing space when optvalue == ''
workaround for: https://github.com/kubernetes/kubernetes/issues/36222 #}
{% endfor %}
}{% endif %}