-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
first cut: Integrating with BGP container
- Loading branch information
1 parent
202589f
commit b75607b
Showing
9 changed files
with
68 additions
and
2 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
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,13 @@ | ||
[ | ||
{ | ||
"tag": "bgp_down", | ||
"regex": "Peer .default\\|([0-9a-f:.]*[0-9a-f]*). admin state is set to .down.", | ||
"params": [ "peer_ip" ] | ||
}, | ||
{ | ||
"tag": "bgp_up", | ||
"regex": "Peer .default\\|([0-9a-f:.]*[0-9a-f]*). admin state is set to .up.", | ||
"params": [ "peer_ip" ] | ||
} | ||
] | ||
|
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,10 @@ | ||
{ | ||
"yang_module": "sonic-events-bgp", | ||
"proclist": [ | ||
{ | ||
"name": "bgpcfgd", | ||
"parse_json": "bgpcfgd_regex.json" | ||
} | ||
] | ||
} | ||
|
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,19 @@ | ||
## rsyslog-plugin for streaming telemetry via gnmi | ||
|
||
|
||
|
||
template(name="prog_msg" type="list") { | ||
property(name="msg") | ||
constant(value="\n") | ||
} | ||
|
||
$ModLoad omprog | ||
|
||
{% for proc in proclist %} | ||
if re_match($programname, "{{ proc.name }}") then { | ||
action(type="omprog" | ||
binary="/usr/share/sonic/scripts/rsyslog_plugin -r /etc/rsyslog.d/{{ proc.parse_json }} -m {{ yang_module }}" | ||
output="/var/log/rsyslog_plugin.log" | ||
template="prog_msg") | ||
} | ||
{% endfor %} |
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
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
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
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
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