Files
awx-operator/roles/backup/templates/event.yml.j2
Lucas Benedito 5697feea57 Fix unquoted timestamps in backup/restore event templates (#2110)
Quote {{ now }} in firstTimestamp and lastTimestamp to prevent
YAML parser from converting the value to a datetime object.

Assisted-by: Claude

Signed-off-by: Lucas Benedito <lbenedit@redhat.com>
2026-03-23 14:11:54 -04:00

18 lines
416 B
Django/Jinja

---
apiVersion: v1
kind: Event
metadata:
name: backup-error.{{ now }}
namespace: "{{ ansible_operator_meta.namespace }}"
involvedObject:
apiVersion: awx.ansible.com/v1beta1
kind: {{ kind }}
name: {{ ansible_operator_meta.name }}
namespace: "{{ ansible_operator_meta.namespace }}"
message: {{ error_msg }}
reason: BackupFailed
type: Warning
firstTimestamp: "{{ now }}"
lastTimestamp: "{{ now }}"
count: 1