OpenVPN/openvpn-connector-setup
4
1
Fork
You've already forked openvpn-connector-setup
0
OpenVPN Connector Setup is a utility to quickly configure OpenVPN 3 Linux to connect to CloudConnexa as a connector.
  • Python 100%
Find a file
David Sommerseth d93b5ef893
Release: openvpn-connector-setup v6
* Added --version option
* Exit with exit code 1 when interrupting the token retrieval
 from console
* Added polkit privilege check to see if the running user
 is allowed to manage systemd unit files. If true, the
 downloaded VPN profile will now be started automatically
 by default, also for limited privileged users.
* Updated the base URL for the CloudConnexa API service.
 The override environment variable has been renamed to
 CLOUDCONNEXA_BASEURL.
* Internal/debug variables has been renamed from
 OPENVPN_CLOUD_ to OPENVPN_CONNECTOR_. To enable
 debugging, the OPENVPN_CONNECTOR_DEBUG environment
 variable must be set instead.
Signed-off-by: David Sommerseth <davids@openvpn.net>
2023年05月22日 09:34:22 +02:00
openvpn Release: openvpn-connector-setup v6 2023年05月22日 09:34:22 +02:00
.gitignore Initial commit of OpenVPN Cloud Connector setup utility 2020年03月19日 21:15:07 +01:00
COPYRIGHT.md Initial commit of OpenVPN Cloud Connector setup utility 2020年03月19日 21:15:07 +01:00
MANIFEST.in Initial commit of OpenVPN Cloud Connector setup utility 2020年03月19日 21:15:07 +01:00
README.md Rebranding: OpenVPN Cloud is renamed to CloudConnexa 2023年04月27日 20:45:12 +02:00
setup.py Add --version to retrieve version and script details 2023年05月15日 21:14:04 +02:00

openvpn-connector-setup

The openvpn-connector-setup tool used to configure the OpenVPN 3 Linux client to connect as a connector in an CloudConnexaTM managed environment.

Before this tool can be used, a connector must already be configured in the CloudConnexaTM portal. As part of this step, the web portal will provide you with a setup token value. This token is mandatory and needed for this tool to configure the host it is being run on.

What does this tool do?

By default this tool will:

  • Download a VPN client configuration profile
  • Configure this VPN profile to be used by openvpn3-autoload at boot time
  • Enable and start the openvpn3-autoload.service systemd unit. This will connect this host to CloudConnexa instantly and ensure it connects automatically each time the host is rebooted.

How to use it

First, configure a new connector in the CloudConnexa portal. When the portal provides you with a setup token, run the script:

[root@host: ~] # openvpn-connector-setup
CloudConnexaTM Connector Setup
This utility is used to configure this host as an OpenVPN Connector
for CloudConnexa. Before this utility can be run, you must have
configured a connector in the CloudConnexa web portal where an setup
token is provided. This token is used by this utility to download the
proper VPN configuration profile and complete the configuration.
Enter setup token: <PROVIDED_TOKEN_VALUE>
Downloading CloudConnexa connector profile ... Done
Importing VPN configuration profile "CloudConnexa" ... Done
Enabling openvpn3-session@CloudConnexa.service during boot ... Done
Starting openvpn3-session@CloudConnexa.service ... Done
[root@host: ~] #

At this point everything should be configured and a VPN connection is established to the CloudConnexa service.

It is also possible to provide the setup token on the command line:

[root@host: ~] # openvpn-connector-setup --token <PROVIDED_TOKEN_VALUE>

Options

-h, --help show a help message and exit
--mode MODE Valid values: systemd-unit (default), autoload - uses openvpn3-autoload to start the connection at boot
--token TOKEN_VALUE This value is provided by the CloudConnexa web portal.
--name NAME Configuration profile name to use. Default: "CloudConnexa"
--force Overwrite existing imported profiles
--autoload-file-prefix PREFIX Configuration filename to use in the /etc/openvpn3/autoload/ directory. Default: CloudConnexa
--no-start Do not configure the profile to start at boot
--dco Use the OpenVPN Data Channel Offload (DCO) by default (unavailable with autoload mode)

Manage VPN configurations and sessions

To further manage the VPN configuration and session see the OpenVPN 3 Linux documentation, in particular these man pages:

Project details

This is an Open Source project and the code is published in three different git repositories

Report issues using Codeberg.

Copyright (C) OpenVPN Inc. This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, version 3 License.