1
0
Fork 0
mirror of https://github.com/Ysurac/openmptcprouter-vps-admin.git synced 2025-02-12 10:31:52 +00:00

Fix adding OpenVPN user

This commit is contained in:
Ycarus (Yannick Chabanois) 2023-12-06 10:02:05 +01:00
parent e4fe9b86a6
commit a671b9171e
2 changed files with 7 additions and 1 deletions

6
debian/changelog vendored
View file

@ -1,3 +1,9 @@
omr-vps-admin (0.7+20231206) unstable; urgency=medium
* Fix adding OpenVPN user
-- OpenMPTCProuter <contact@openmptcprouter.com> Tue, 03 Dec 2023 09:58:24 +0200
omr-vps-admin (0.7+20231128) unstable; urgency=medium
* Fix global settings in json

View file

@ -3092,7 +3092,7 @@ def add_user(*, params: NewUser, current_user: User = Depends(get_current_user))
LOG.debug("Empty data for add_user")
# Create VPNs configuration
if os.path.isfile('/etc/openvpn/tun0.conf'):
os.system('cd /etc/openvpn/ca && EASYRSA_CERT_EXPIRE=3650 ./easyrsa build-client-full "' + params.username + '" nopass')
os.system('cd /etc/openvpn/ca && EASYRSA_CERT_EXPIRE=3650 ./easyrsa --batch build-client-full "' + params.username + '" nopass')
if os.path.isfile('/etc/glorytun-tcp/tun0'):
add_glorytun_tcp(userid)
if os.path.isfile('/etc/glorytun-udp/tun0'):