X-Git-Url: https://git.llucax.com/software/pymin.git/blobdiff_plain/756a0232952c65c75bcd39b4345490a403cefb73..980addbad2fa349befff4f22034b09afb489c9e0:/services/vpn/__init__.py diff --git a/services/vpn/__init__.py b/services/vpn/__init__.py index 0e2747a..5071c7e 100644 --- a/services/vpn/__init__.py +++ b/services/vpn/__init__.py @@ -1,7 +1,17 @@ # vim: set encoding=utf-8 et sw=4 sts=4 : +from formencode import validators as V +from pymin.config import Option from handler import VpnHandler +def setup_service(options, config): + options.add_group('vpn', 'Virtual Private Networking service', [ + Option('pickle_dir', V.String, metavar='DIR', + help='store persistent data in DIR directory'), + Option('config_dir', V.String, metavar='DIR', + help='write config file in DIR directory'), + ]) + def get_service(config): return VpnHandler(config.vpn.pickle_dir, config.vpn.config_dir)