From 9117d620ff6908ce92318db216403dab68c496ed Mon Sep 17 00:00:00 2001 From: Christian Pointner Date: Sat, 5 Mar 2022 21:55:14 +0100 Subject: initial commit for alerta role --- roles/monitoring/alerta/templates/pod-spec.yml.j2 | 48 +++++++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 roles/monitoring/alerta/templates/pod-spec.yml.j2 (limited to 'roles/monitoring/alerta/templates/pod-spec.yml.j2') diff --git a/roles/monitoring/alerta/templates/pod-spec.yml.j2 b/roles/monitoring/alerta/templates/pod-spec.yml.j2 new file mode 100644 index 00000000..e31686e3 --- /dev/null +++ b/roles/monitoring/alerta/templates/pod-spec.yml.j2 @@ -0,0 +1,48 @@ +containers: +- name: alerta + image: "alerta/alerta-web:8.7.0" + resources: + limits: + memory: "1Gi" + env: + - name: "DATABASE_URL" + value: "postgres://alerta:secret@127.0.0.1:5432/alerta" + - name: "AUTH_REQUIRED" + value: "True" + - name: "ADMIN_USERS" + value: "admin" + volumeMounts: + - name: config + mountPath: /app/alertad.conf.j2 + subPath: alertad.conf.j2 + readOnly: true + ports: + - containerPort: 8080 + hostPort: 8080 + +- name: postgresql + image: "postgres:14.2" + args: + - postgres + - -c + - listen_addresses=127.0.0.1 + env: + - name: "POSTGRES_DB" + value: "alerta" + - name: "POSTGRES_USER" + value: "alerta" + - name: "POSTGRES_PASSWORD" + value: "secret" + volumeMounts: + - name: postgres + mountPath: /var/lib/postgresql/data + +volumes: +- name: config + hostPath: + path: "{{ alerta_base_path }}/config" + type: Directory +- name: postgres + hostPath: + path: "{{ alerta_base_path }}/postgres" + type: Directory -- cgit v1.2.3