diff options
author | jjakob <jernej.jakob@gmail.com> | 2020-04-13 12:38:40 +0200 |
---|---|---|
committer | jjakob <jernej.jakob@gmail.com> | 2020-04-13 12:38:40 +0200 |
commit | fbdf1e4d175079d726124a695b584e62e0530834 (patch) | |
tree | 53015f79d68a22fb84076f487f0154ee387bb391 | |
parent | 1fa62cd27ad535669cd62cb2e0560ff840681281 (diff) | |
download | vyos-1x-fbdf1e4d175079d726124a695b584e62e0530834.tar.gz vyos-1x-fbdf1e4d175079d726124a695b584e62e0530834.zip |
openvpn: T2283: move ccd to /run/openvpn
Commit a457c9d2 moved the config directory to /run/openvpn but didn't move
the client-config-dir in the template.
-rw-r--r-- | data/templates/openvpn/server.conf.tmpl | 2 | ||||
-rwxr-xr-x | src/conf_mode/interfaces-openvpn.py | 8 |
2 files changed, 5 insertions, 5 deletions
diff --git a/data/templates/openvpn/server.conf.tmpl b/data/templates/openvpn/server.conf.tmpl index 340ead269..c909f4337 100644 --- a/data/templates/openvpn/server.conf.tmpl +++ b/data/templates/openvpn/server.conf.tmpl @@ -85,7 +85,7 @@ max-clients {{ server_max_conn }} {%- endif %} {%- if client %} -client-config-dir /opt/vyatta/etc/openvpn/ccd/{{ intf }} +client-config-dir /run/openvpn/ccd/{{ intf }} {%- endif %} {%- if server_reject_unconfigured %} diff --git a/src/conf_mode/interfaces-openvpn.py b/src/conf_mode/interfaces-openvpn.py index 85945ba58..66b96debe 100755 --- a/src/conf_mode/interfaces-openvpn.py +++ b/src/conf_mode/interfaces-openvpn.py @@ -666,10 +666,10 @@ def generate(openvpn): directories = [] directories.append(f'{directory}/status') directories.append(f'{directory}/ccd/{interface}') - for directory in directories: - if not os.path.exists(directory): - os.makedirs(directory, 0o755) - chown(directory, user, group) + for onedir in directories: + if not os.path.exists(onedir): + os.makedirs(onedir, 0o755) + chown(onedir, user, group) # Fix file permissons for keys fix_permissions = [] |