mirror of
https://github.com/ansible/awx-operator.git
synced 2026-03-26 21:33:14 +00:00
* Add resource specification options to the backup objects * Add resource specification options to the restore object Co-authored-by: Ivan Aragonés <26822043+ivarmu@users.noreply.github.com> Co-authored-by: silvinux <silvinux7@gmail.com> Co-authored-by: Ivan Aragonés Muniesa <iaragone@redhat.com>
33 lines
1.1 KiB
Django/Jinja
33 lines
1.1 KiB
Django/Jinja
---
|
|
apiVersion: v1
|
|
kind: Pod
|
|
metadata:
|
|
name: {{ ansible_operator_meta.name }}-db-management
|
|
namespace: {{ backup_pvc_namespace }}
|
|
labels:
|
|
app.kubernetes.io/name: '{{ ansible_operator_meta.name }}'
|
|
app.kubernetes.io/part-of: '{{ ansible_operator_meta.name }}'
|
|
app.kubernetes.io/managed-by: '{{ deployment_type }}-operator'
|
|
app.kubernetes.io/component: '{{ deployment_type }}'
|
|
app.kubernetes.io/operator-version: '{{ lookup("env", "OPERATOR_VERSION") }}'
|
|
spec:
|
|
containers:
|
|
- name: {{ ansible_operator_meta.name }}-db-management
|
|
image: "{{ _postgres_image }}"
|
|
imagePullPolicy: Always
|
|
command: ["sleep", "infinity"]
|
|
volumeMounts:
|
|
- name: {{ ansible_operator_meta.name }}-backup
|
|
mountPath: /backups
|
|
readOnly: false
|
|
{% if backup_resource_requirements is defined %}
|
|
resources:
|
|
{{ backup_resource_requirements | to_nice_yaml(indent=2) | indent(width=6, indentfirst=False) }}
|
|
{%- endif %}
|
|
volumes:
|
|
- name: {{ ansible_operator_meta.name }}-backup
|
|
persistentVolumeClaim:
|
|
claimName: {{ backup_claim }}
|
|
readOnly: false
|
|
restartPolicy: Never
|