Make sure we remove openvpn file AFTER slapos installation.

SlapOS package will readd it.
parent c0198103
......@@ -286,12 +286,6 @@ def slapserver(config):
os.chown(ssh_key_path, uid, gid)
os.chmod(ssh_key_path, 0600)
# Put file to force VPN if user asked
if not config.force_vpn :
if not dry_run:
_call(['rm','-f',
os.path.join(config.slapos_configuration,'openvpn-needed')])
# Put file to force VPN if user asked
if config.force_slapcontainer :
if not dry_run:
......@@ -321,6 +315,7 @@ def slapserver(config):
print "Removing %r" % path
if not dry_run:
os.remove(path)
finally:
print "SlapOS Image configuration: DONE"
return 0
......@@ -562,6 +557,10 @@ def slapprepare():
configureNtp()
# Remove use of openvpn if not explicitely defined
if not config.force_vpn and not config.dry_run:
os.remove(os.path.join(config.slapos_configuration, 'openvpn-needed'))
# Enable and run slapos-boot-dedicated.service
_call(['systemctl','enable','slapos-boot-dedicated.service'])
_call(['systemctl','start','slapos-boot-dedicated.service'])
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment