From 27c9d7fd077b78e9b80b4c8481d5da422c16283d Mon Sep 17 00:00:00 2001 From: "CanbiZ (MickLesk)" <47820557+MickLesk@users.noreply.github.com> Date: Tue, 17 Mar 2026 23:59:40 +0100 Subject: [PATCH] fix(gluetun): add OpenVPN process user and cleanup stale config (#13016) - Add OPENVPN_PROCESS_USER=root, PUID=0, PGID=0 to default .env to prevent gluetun from injecting 'user' directive into target.ovpn which causes 'Unrecognized option' errors on Debian - Add ExecStartPre to remove stale /etc/openvpn/target.ovpn before start - Fixes #12988 --- install/gluetun-install.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/install/gluetun-install.sh b/install/gluetun-install.sh index 9ba623d46..68e841d93 100644 --- a/install/gluetun-install.sh +++ b/install/gluetun-install.sh @@ -46,6 +46,9 @@ VPN_TYPE=openvpn OPENVPN_CUSTOM_CONFIG=/opt/gluetun-data/custom.ovpn OPENVPN_USER= OPENVPN_PASSWORD= +OPENVPN_PROCESS_USER=root +PUID=0 +PGID=0 HTTP_CONTROL_SERVER_ADDRESS=:8000 HTTPPROXY=off SHADOWSOCKS=off @@ -76,6 +79,7 @@ User=root WorkingDirectory=/opt/gluetun-data EnvironmentFile=/opt/gluetun-data/.env UnsetEnvironment=USER +ExecStartPre=/bin/sh -c 'rm -f /etc/openvpn/target.ovpn' ExecStart=/usr/local/bin/gluetun Restart=on-failure RestartSec=5