generated from ansible-collections/collection_template
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
52 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
{ | ||
"CompanyID": 24761, | ||
"CurrentState": "n/a", | ||
"Description": "Insight for Through Site Comparison", | ||
"Dimensions": {}, | ||
"EndTime": "2022-11-02 13:50:00 UTC", | ||
"InsightDataSourceType": "ksql", | ||
"InsightID": "k654321097", | ||
"InsightName": "operate.site.bpsThroughWeekOverWeek", | ||
"InsightPlainDescription": "Foobar Amsterdam AMS13 had 22% more through traffic (+139 Kbits/s) this week compared to last week.", | ||
"IsActive": true, | ||
"Links": { | ||
"InsightDetailsURL": "https://portal.kentik.com/v4/operate/insights/k611587433", | ||
"InsightsMainURL": "https://portal.kentik.com/v4/operate/insights", | ||
"InsightsSeverityURL": "https://portal.kentik.com/v4/operate/insights?severities=notice" | ||
}, | ||
"Metrics": {}, | ||
"PreviousState": "n/a", | ||
"StartTime": "2022-11-02 11:50:00 UTC", | ||
"Type": "EVENT_VIEW_TYPE_INSIGHT", | ||
"issue": [], | ||
"statistic": {} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
--- | ||
- name: Kentik event-driven-ansible test | ||
hosts: localhost # use for local testing of the plugin | ||
tasks: | ||
- name: Print Kentik alert | ||
ansible.buitlin.debug: | ||
msg: "{{ ansible_eda.event.payload }}" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
--- | ||
- name: Listen for alerts using kentik_webhook | ||
hosts: all | ||
|
||
## Define our source for events | ||
|
||
sources: | ||
- kentik.ansible_eda.kentik_webhook: | ||
host: 0.0.0.0 | ||
port: 80 | ||
|
||
## Define the conditions we are looking for | ||
|
||
rules: | ||
- name: Say Hello | ||
condition: event.i == 1 | ||
|
||
## Define the action we should take should the condition be met | ||
|
||
action: | ||
run_playbook: | ||
name: playbooks/example_playbook.yml |