Skip to content

Commit 0673426

Browse files
committed
scope in post_event_simple
1 parent 85a9f39 commit 0673426

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

examples/post_event_simple.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,9 @@
2020
name = sys.argv[2]
2121
description = sys.argv[3]
2222

23+
scope='host.hostName = "foo" and container.name = "bar"'
24+
tags={"tag1" : "value1"}
25+
2326
severity = 6
2427
if len(sys.argv) < 4:
2528
severity = int(sys.argv[4])
@@ -32,7 +35,7 @@
3235
#
3336
# Post the event
3437
#
35-
res = sdclient.post_event(name, description, severity, tags={"tag1" : "value1"})
38+
res = sdclient.post_event(name, description, severity, scope, tags)
3639

3740
#
3841
# Return the result

0 commit comments

Comments
 (0)