c74b147fe7
These are mostly CI fixes: * Use podman+cri-o based minikube: * This is still considered experimental, but seems to be more supported than the 'none' driver. * Fix an issue where ssh to the emulated static node fails: * PAM needed to be disabled for openssh * openssh needs more permissions to run - cri-o based minikube is more strict * Rebase test container to Fedora 40 * Update the ingress definition to current API version * Update zookeeper from 3.5.5 to 3.8.4: * required for nodepool 9.0.0+ * Update the percona operator from 1.11 to 1.14: * required for kubernetes 1.24+ * Update test node to Ubuntu Jammy from Ubuntu Bionic * Update minikube to 1.33.1 * Added some more explicit logging to the k8s state, this could be split off into a role in future. Depends-On: https://review.opendev.org/c/zuul/zuul-jobs/+/924970 Change-Id: I7bf27750073fa807069af6f85f2689173b278abe
80 lines
2.0 KiB
YAML
80 lines
2.0 KiB
YAML
- name: Create static node image
|
|
when: "runtime == 'minikube'"
|
|
args:
|
|
chdir: "{{ zuul_work_dir }}/playbooks/zuul-operator-functional/static-node"
|
|
shell: |
|
|
minikube image build . -t static-node
|
|
|
|
- name: Create static node image
|
|
when: "runtime == 'kind'"
|
|
args:
|
|
chdir: "{{ zuul_work_dir }}/playbooks/zuul-operator-functional/static-node"
|
|
shell: |
|
|
docker build . -t static-node
|
|
kind load docker-image static-node
|
|
|
|
- name: Run static node
|
|
k8s:
|
|
namespace: "default"
|
|
definition:
|
|
apiVersion: v1
|
|
kind: Pod
|
|
metadata:
|
|
name: node
|
|
labels:
|
|
app: static-node
|
|
spec:
|
|
containers:
|
|
- name: node
|
|
image: static-node
|
|
imagePullPolicy: Never
|
|
lifecycle:
|
|
postStart:
|
|
exec:
|
|
command:
|
|
- bash
|
|
- -c
|
|
- mkdir -p /root/.ssh && chmod 0600 /root/.ssh && cp /sshkeys/authorized_keys /root/.ssh
|
|
ports:
|
|
- name: ssh
|
|
containerPort: 22
|
|
protocol: TCP
|
|
- name: zuul
|
|
containerPort: 19885
|
|
protocol: TCP
|
|
securityContext:
|
|
allowPrivilegeEscalation: true
|
|
privileged: true
|
|
capabilities:
|
|
add: ["SYS_ADMIN"]
|
|
volumeMounts:
|
|
- name: authorized-keys
|
|
mountPath: /sshkeys
|
|
readOnly: true
|
|
volumes:
|
|
- name: authorized-keys
|
|
secret:
|
|
secretName: static-node-authorized-keys
|
|
defaultMode: 0600
|
|
|
|
- name: Create static node service
|
|
k8s:
|
|
namespace: "default"
|
|
definition:
|
|
apiVersion: v1
|
|
kind: Service
|
|
metadata:
|
|
name: node
|
|
spec:
|
|
selector:
|
|
app: static-node
|
|
ports:
|
|
- name: ssh
|
|
port: 22
|
|
targetPort: 22
|
|
protocol: TCP
|
|
- name: zuul
|
|
port: 19885
|
|
targetPort: 19885
|
|
protocol: TCP
|