diff options
author | Daniil Baturin <daniil@baturin.org> | 2019-09-01 06:19:31 +0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-09-01 06:19:31 +0700 |
commit | 3075c019effb570b595bc2acc2d33cf5f55b6675 (patch) | |
tree | 05d26dfd75a8e0b618980838b229ca14223ed5a2 /python | |
parent | 0e032f5df4f567195abc7562e8cf6b1164eeec7b (diff) | |
parent | 86d1291ec5323e921a0f995211e223bf1f7dcdff (diff) | |
download | vyos-1x-3075c019effb570b595bc2acc2d33cf5f55b6675.tar.gz vyos-1x-3075c019effb570b595bc2acc2d33cf5f55b6675.zip |
Merge pull request #123 from jestabro/current
[boot-config-loader] T1622: Add failsafe and back trace
Diffstat (limited to 'python')
-rw-r--r-- | python/vyos/configsession.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/python/vyos/configsession.py b/python/vyos/configsession.py index 8626839f2..acbdd3d5f 100644 --- a/python/vyos/configsession.py +++ b/python/vyos/configsession.py @@ -24,6 +24,7 @@ COMMENT = '/opt/vyatta/sbin/my_comment' COMMIT = '/opt/vyatta/sbin/my_commit' DISCARD = '/opt/vyatta/sbin/my_discard' SHOW_CONFIG = ['/bin/cli-shell-api', 'showConfig'] +LOAD_CONFIG = ['/bin/cli-shell-api', 'loadFile'] # Default "commit via" string APP = "vyos-http-api" @@ -155,3 +156,5 @@ class ConfigSession(object): if format == 'raw': return config_data + def load_config(self, file_path): + self.__run_command(LOAD_CONFIG + [file_path]) |