Merge "Mount connection sshkeys on executors and mergers"

This commit is contained in:
Zuul 2021-08-05 17:42:52 +00:00 committed by Gerrit Code Review
commit 345cda5b66
1 changed files with 28 additions and 0 deletions

View File

@ -345,6 +345,13 @@ spec:
mountPath: {{ volume.path }}
{%- if volume.access == 'ro' %}readOnly: true{% endif %}
{%- endfor %}
{%- for connection_name, connection in connections.items() %}
{%- if 'secretName' in connection %}
- name: connection-{{ connection_name }}
mountPath: /etc/zuul/connections/{{ connection_name }}
readOnly: true
{%- endif %}
{%- endfor %}
securityContext:
privileged: true
terminationGracePeriodSeconds: {{ spec.executor.terminationGracePeriodSeconds }}
@ -371,6 +378,13 @@ spec:
{%- for volume in spec.get('jobVolumes', []) %}
- {{ volume.volume | zuul_to_json }}
{%- endfor %}
{%- for connection_name, connection in connections.items() %}
{%- if 'secretName' in connection %}
- name: connection-{{ connection_name }}
secret:
secretName: {{ connection['secretName'] }}
{%- endif %}
{%- endfor %}
---
apiVersion: apps/v1
kind: StatefulSet
@ -415,6 +429,13 @@ spec:
- name: zookeeper-client-tls
mountPath: /tls/client
readOnly: true
{%- for connection_name, connection in connections.items() %}
{%- if 'secretName' in connection %}
- name: connection-{{ connection_name }}
mountPath: /etc/zuul/connections/{{ connection_name }}
readOnly: true
{%- endif %}
{%- endfor %}
terminationGracePeriodSeconds: 3600
volumes:
- name: zuul-var
@ -425,6 +446,13 @@ spec:
- name: zookeeper-client-tls
secret:
secretName: {{ spec.zookeeper.secretName }}
{%- for connection_name, connection in connections.items() %}
{%- if 'secretName' in connection %}
- name: connection-{{ connection_name }}
secret:
secretName: {{ connection['secretName'] }}
{%- endif %}
{%- endfor %}
---
apiVersion: v1
kind: Service