summaryrefslogtreecommitdiff
path: root/src/conf_mode
diff options
context:
space:
mode:
authorChristian Breunig <christian@breunig.cc>2023-03-17 20:09:31 +0100
committerGitHub <noreply@github.com>2023-03-17 20:09:31 +0100
commitc820be57b6c77cdb0a5055d0c3a77dc8d550e2d7 (patch)
treeb9d65f6aff120b793a8838c445825f348da2c6a1 /src/conf_mode
parent92c3ce9fbc266bbbd89a40fe0c98d6db1a4f4c2c (diff)
parent9d3f88170fabd2211d51a56a642b388529ec385a (diff)
downloadvyos-1x-c820be57b6c77cdb0a5055d0c3a77dc8d550e2d7.tar.gz
vyos-1x-c820be57b6c77cdb0a5055d0c3a77dc8d550e2d7.zip
Merge pull request #1898 from sever-sever/T5086-def
T5086: Fix sflow fix default values for server
Diffstat (limited to 'src/conf_mode')
-rwxr-xr-xsrc/conf_mode/system_sflow.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/conf_mode/system_sflow.py b/src/conf_mode/system_sflow.py
index 2e19a5d76..a0c3fca7f 100755
--- a/src/conf_mode/system_sflow.py
+++ b/src/conf_mode/system_sflow.py
@@ -57,6 +57,12 @@ def get_config(config=None):
if 'port' in sflow['server']:
del sflow['server']['port']
+ # Set default values per server
+ if 'server' in sflow:
+ for server in sflow['server']:
+ default_values = defaults(base + ['server'])
+ sflow['server'][server] = dict_merge(default_values, sflow['server'][server])
+
return sflow