Skip to content

Commit

Permalink
get_full_config script for gnmi added
Browse files Browse the repository at this point in the history
  • Loading branch information
Tomas Kubina committed Jun 20, 2022
1 parent 1869add commit 86add1d
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions gnmi_examples/get_full_config.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
from pygnmi.client import gNMIclient
import json

host = ('192.168.243.21', '50001')

with gNMIclient(target=host, username='nsouser', password='Welcome41', insecure=True, debug=0) as gc:
result = gc.get(path=[], encoding='json_ietf', datatype='config')
print(json.dumps(result, indent=4))

0 comments on commit 86add1d

Please sign in to comment.