From 2c90c0d7c8d3bef95c1397c199bb53f7847743d7 Mon Sep 17 00:00:00 2001 From: Christian Poessinger Date: Sat, 3 Oct 2020 19:57:06 +0200 Subject: sstp: T2953: migrate name-server settions to common level In order to reuse as much as possible before migrationg to get_config_dict() and re-use Jinja2 snippets the name-server node must be moved one level up to 'set vpn sstp name-server'. --- src/migration-scripts/sstp/2-to-3 | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src/migration-scripts/sstp/2-to-3') diff --git a/src/migration-scripts/sstp/2-to-3 b/src/migration-scripts/sstp/2-to-3 index 51f4effed..db705f5eb 100755 --- a/src/migration-scripts/sstp/2-to-3 +++ b/src/migration-scripts/sstp/2-to-3 @@ -39,6 +39,11 @@ else: if config.exists(base_path + ['ppp-settings']): config.rename(base_path + ['ppp-settings'], 'ppp-options') + config_ns = base_path + ['network-settings', 'name-server'] + if config.exists(config_ns): + config.copy(config_ns, base_path + ['name-server']) + config.delete(config_ns) + try: with open(file_name, 'w') as f: f.write(config.to_string()) -- cgit v1.2.3