Compare commits
2 Commits
19f498e091
...
c8485bc35b
| Author | SHA1 | Date | |
|---|---|---|---|
|
c8485bc35b
|
|||
|
51709f6ee9
|
4
.gitignore
vendored
4
.gitignore
vendored
@@ -268,4 +268,6 @@ context/
|
|||||||
collections/ansible_collections/
|
collections/ansible_collections/
|
||||||
.vault_password
|
.vault_password
|
||||||
secrets.yml
|
secrets.yml
|
||||||
.swp
|
.swp
|
||||||
|
# Ignore vscode
|
||||||
|
.vscode/
|
||||||
|
|||||||
2
.vscode/settings.json
vendored
2
.vscode/settings.json
vendored
@@ -1,3 +1,3 @@
|
|||||||
{
|
{
|
||||||
"ansible.python.interpreterPath": "/var/home/ptoal/.virtualenvs/ansible/bin/python"
|
"ansible.python.interpreterPath": "/home/ptoal/.virtualenvs/ansible/bin/python"
|
||||||
}
|
}
|
||||||
20
rulebooks/alertmanager_listener.yml
Normal file
20
rulebooks/alertmanager_listener.yml
Normal file
@@ -0,0 +1,20 @@
|
|||||||
|
---
|
||||||
|
- name: Listen for Alertmanager events
|
||||||
|
hosts: all
|
||||||
|
sources:
|
||||||
|
- name: Ansible Alertmanager listener
|
||||||
|
ansible.eda.alertmanager:
|
||||||
|
port: 9100
|
||||||
|
host: 0.0.0.0
|
||||||
|
rules:
|
||||||
|
- name: Run Template
|
||||||
|
condition:
|
||||||
|
all:
|
||||||
|
- event.payload.data.artifact_url is defined
|
||||||
|
action:
|
||||||
|
run_job_template:
|
||||||
|
name: bab-deploy-application
|
||||||
|
organization: OYS
|
||||||
|
job_args:
|
||||||
|
extra_vars:
|
||||||
|
artifact_url: "{{ event.payload.data.artifact_url }}"
|
||||||
Reference in New Issue
Block a user