Help Needed: Gluetun VPN Container "User is Empty" Error on TrueNAS SCALE

I have found that you now need to go through all this to get a vpn to work with a torrent app on scale nowadays. This is my best effort.

I’m trying to setup a VPN-enabled qBittorrent stack using the Gluetun container on my TrueNAS SCALE system. Despite trying multiple configurations and troubleshooting steps, I keep encountering the following error in the Gluetun logs:

ERROR VPN settings: OpenVPN settings: user is empty

My Setup

  • TrueNAS SCALE version: ElectricEel-24.10.1
  • Gluetun image version: qmcgaw/gluetun:latest
  • qBittorrent image version: lscr.io/linuxserver/qbittorrent:latest
  • VPN provider: Premiumize.me

What I’ve Tried

1. Ensuring Proper Files and Mounts

  • Mounted the following files to /config inside the container:
    • config.ovpn
    • credentials.txt containing the VPN username and password.
  • Confirmed that the .ovpn file references the credentials:
    auth-user-pass /config/credentials.txt
    
  • Verified file access inside the container using:
    sudo docker run --rm -it \
        --entrypoint /bin/ls \
        -v /mnt/basepool/aplications/gluetun:/config \
        qmcgaw/gluetun /config
    
    Files were present and readable.

2. Adjusting Permissions

  • Ensured the files are owned by PUID=3003 and PGID=3003 (the user and group running the container).
  • Set restrictive permissions on the files:
    sudo chmod 600 /mnt/basepool/aplications/gluetun/config.ovpn
    sudo chmod 600 /mnt/basepool/aplications/gluetun/credentials.txt
    

3. Testing Environment Variables

  • Removed unnecessary or conflicting variables in the docker-compose.yml:
    environment:
      - VPN_TYPE=openvpn
      - OPENVPN_CUSTOM_CONFIG=/config/config.ovpn
      - PUID=3003
      - PGID=3003
      - LOG_LEVEL=debug
    
  • Also tested adding OPENVPN_USER and OPENVPN_PASSWORD directly:
environment:
  - OPENVPN_USER=387728620
  - OPENVPN_PASSWORD=password

However, the issue persisted.

4. Manually Running OpenVPN

  • Attempted to manually test the .ovpn file inside the Gluetun container, but the openvpn binary is not available:
    sudo docker run --rm -it \
        --entrypoint /usr/sbin/openvpn \
        qmcgaw/gluetun --config /config/config.ovpn
    
    Result: no such file or directory

5. Testing with a Minimal OpenVPN Container

  • Used the dperson/openvpn-client image to verify the .ovpn configuration:

    sudo docker run --rm -it \
        -v /mnt/basepool/aplications/gluetun:/vpn \
        dperson/openvpn-client openvpn --config /vpn/config.ovpn
    

    Result: The container failed with the following errors:

    • WARNING: cannot stat file '/config/credentials.txt': No such file or directory
    • Options error: --auth-user-pass fails with '/config/credentials.txt': No such file or directory

    This suggests that the credentials.txt file was not correctly mapped or accessible in the /config directory.

6. Testing on a Linux Desktop

  • Tested the same .ovpn file and credentials on a Linux desktop using OpenVPN directly. The credentials worked, and the connection established up to a point before encountering unrelated errors. This confirms the .ovpn file and credentials are valid.

7. Considering Alternatives

  • Explored switching to the haugene/transmission-openvpn container, which integrates OpenVPN and torrenting:
    sudo docker run --rm -it \
        -v /mnt/basepool/aplications/gluetun:/config \
        -e OPENVPN_CONFIG=config.ovpn \
        haugene/transmission-openvpn
    
    However, I’d prefer to stick with qBittorrent if possible.

Logs

Here is the recurring error from Gluetun:

2025-01-01T23:28:05Z ERROR VPN settings: OpenVPN settings: user is empty

Request for Help

I’m at a loss as to why Gluetun isn’t reading the credentials correctly, especially since they’re accessible and correctly referenced in the .ovpn file. Have I missed something in the configuration? Does anyone have experience with Gluetun and Premiumize.me or other tips to resolve this issue?

Thank you in advance for your time and assistance!

Full configs (redacted) for ref:

jack@TruenasScale /mnt/basepool/aplications/gluetun $ cat config.ovpn 
remote vpn-nl.premiumize.me
verify-x509-name CN=vpn-nl.premiumize.me
auth-user-pass /config/credentials.txt
client
dev tun
proto udp
cipher AES-256-CBC
resolv-retry infinite
nobind
persist-key
persist-tun
mute-replay-warnings
verb 3
reneg-sec 0
setenv CLIENT_CERT 0
ignore-unknown-option block-outside-dns
<ca>
-----BEGIN CERTIFICATE-----
MIIFJTCCAw2gAwIBAgIRAPAmbQRNE+PBqvFyFG8GOSIwDQYJKoZIhvcNAQELBQAw
LDEYMBYGA1UECgwPU2VjdXJlIFNlcnZpY2VzMRAwDgYDVQQDDAdSb290IFgxMB4X
DTIxMDEwNDE1MjEwM1oXDTQwMTIzMDE1MjEwM1owLDEYMBYGA1UECgwPU2VjdXJl
IFNlcnZpY2VzMRAwDgYDVQQDDAdSb290IFgxMIICIjANBgkqhkiG9w0BAQEFAAOC
Ag8AMIICCgKCAgEAvuhFcbO0Y5SXBr+h/XU1sPXo/OSjN4W32jzVZ3jmkqA2nH5D
dI5XYHYB9JkW23K37zOlvOWj9J3HiV6WYk0uqQ3cpqDMnIpi1MJCtSRxiaD7LTNO

jack@TruenasScale /mnt/basepool/aplications/gluetun $ cat credentials.txt 
387728620
password

.yaml

version: "3"
services:
  gluetun:
    image: qmcgaw/gluetun
    container_name: gluetun
    cap_add:
      - NET_ADMIN
    devices:
      - /dev/net/tun:/dev/net/tun
    ports:
      - 8888:8888/tcp # HTTP proxy
      - 8388:8388/tcp # Shadowsocks
      - 8388:8388/udp # Shadowsocks
      - 8080:8080 # qBittorrent WebUI
      - 6881:6881 # Torrenting port
      - 6881:6881/udp # Torrenting port
    volumes:
      - /mnt/basepool/aplications/gluetun:/config
      - /mnt/basepool/aplications/gluetun/config.ovpn:/gluetun/config.ovpn
    environment:
      - VPN_TYPE=openvpn
      - OPENVPN_CUSTOM_CONFIG=/config/config.ovpn
      - PUID=3003
      - PGID=3003
      - FIREWALL_VPN_INPUT_PORTS=8080,6881
      - LOG_LEVEL=debug
    restart: unless-stopped
  qbittorrent:
    image: lscr.io/linuxserver/qbittorrent:latest
    container_name: qbittorrent
    environment:
      - PUID=3003
      - PGID=3003
      - TZ=GMT+1
      - WEBUI_PORT=8080
      - TORRENTING_PORT=6881
    volumes:
      - /mnt/basepool/aplications/qbittorrent/qbitconfig:/config
      - /mnt/basepool/aplications/qbittorrent/media:/downloads
    restart: unless-stopped
    network_mode: container:gluetun
networks: {}

iv exhausted the AI even though i pay for the full subscription, i just kept going for 48 hours straight. I have tried and tried.

I built just the most simplest form of vpn that i can

version: "3"
services:
  gluetun:
    image: dperson/openvpn-client
    container_name: gluetun-test
    cap_add:
      - NET_ADMIN
    devices:
      - /dev/net/tun:/dev/net/tun
    ports:
      - 8888:8888/tcp # HTTP proxy
      - 8388:8388/tcp # Shadowsocks
      - 8388:8388/udp # Shadowsocks
      - 8080:8080 # Example service
      - 6881:6881 # Torrent
      - 6881:6881/udp # Torrent
    volumes:
      - /mnt/basepool/aplications/gluetun:/vpn
    environment:
      - OPENVPN_CUSTOM_CONFIG=/vpn/config.ovpn
      - LOG_LEVEL=info
    dns:
      - 1.1.1.1
      - 1.0.0.1
    restart: unless-stopped
networks: {}
jack@TruenasScale ~ $ sudo docker run -it --cap-add=NET_ADMIN --device=/dev/net/tun \
-v /mnt/basepool/aplications/gluetun:/vpn \
dperson/openvpn-client openvpn --config /vpn/config.ovpn
Dump terminated
Thu Jan  2 14:43:23 2025 WARNING: file '/vpn/credentials.txt' is group or others accessible
Thu Jan  2 14:43:23 2025 OpenVPN 2.4.9 x86_64-alpine-linux-musl [SSL (OpenSSL)] [LZO] [LZ4] [EPOLL] [MH/PKTINFO] [AEAD] built on Apr 20 2020
Thu Jan  2 14:43:23 2025 library versions: OpenSSL 1.1.1g  21 Apr 2020, LZO 2.10
Thu Jan  2 14:43:23 2025 TCP/UDP: Preserving recently used remote address: [AF_INET]185.107.94.249:1194
Thu Jan  2 14:43:23 2025 Socket Buffers: R=[212992->212992] S=[212992->212992]
Thu Jan  2 14:43:23 2025 UDP link local: (not bound)
Thu Jan  2 14:43:23 2025 UDP link remote: [AF_INET]185.107.94.249:1194
Thu Jan  2 14:43:23 2025 TLS: Initial packet from [AF_INET]185.107.94.249:1194, sid=756d4953 6cffac80
Thu Jan  2 14:43:23 2025 WARNING: this configuration may cache passwords in memory -- use the auth-nocache option to prevent this
Thu Jan  2 14:43:23 2025 VERIFY OK: depth=2, O=Secure Services, CN=Root X1
Thu Jan  2 14:43:23 2025 VERIFY OK: depth=1, O=Secure Services, CN=Intermediate X5
Thu Jan  2 14:43:23 2025 VERIFY X509NAME OK: CN=vpn-nl.premiumize.me
Thu Jan  2 14:43:23 2025 VERIFY OK: depth=0, CN=vpn-nl.premiumize.me
Thu Jan  2 14:43:26 2025 Control Channel: TLSv1.3, cipher TLSv1.3 TLS_AES_256_GCM_SHA384, 2048 bit RSA
Thu Jan  2 14:43:26 2025 [vpn-nl.premiumize.me] Peer Connection Initiated with [AF_INET]185.107.94.249:1194
Thu Jan  2 14:43:26 2025 AUTH: Received control message: AUTH_FAILED
Thu Jan  2 14:43:26 2025 SIGTERM[soft,auth-failure] received, process exiting
jack@TruenasScale ~ $ 

But my credentials are 100% correct.

This is probably a silly question but when you used environmental variables to specify login info did you use quotes around the username and pw?

Per this page, it looks like you need to but I don’t have much experience with openvpn in Gluetun.

errr, nop, hmm. is it important ? i assume so since you would mention it otherwise.

I shall go have a read of what you have, give it a try (iv deleted everything now)

But yea it was my first attempt at a Dockge mashup of Gluetun, openvpn & qbittorrent via yaml. Well mty first attempt at anything Docker at all.

When Gluetun is reading the config from the docker compose file, it might need the username/pw to be in quotes to properly utilize them. This is purely a guess on my part but the documentation shows the username and pw in quotes.

yea , makes sense.

Well it did change, from

2025-01-01T23:28:05Z ERROR VPN settings: OpenVPN settings: user is empty

to
gluetun-test | Thu Jan 2 16:40:24 2025 AUTH: Received control message: AUTH_FAILED

I am 100% sure my credentials are correct.

So its a movement forward and i really appreciate that :slight_smile: i shall keep at it.

Did you follow the sample compose for using custom VPN with Gluetun:

Also, is it possible that openvpn doesn’t like certain characters in your password? I ran into that issue with Truechart’s qbt/openvpn app when I first installed Scale 2 years ago.

yea i tried :frowning:

jack@TruenasScale ~ $ sudo docker run -it --rm --cap-add=NET_ADMIN -e VPN_SERVICE_PROVIDER=custom -e VPN_TYPE=openvpn -v /mnt/basepool/aplications/gluetun/config.ovpn:/gluetun/config.ovpn:ro -e OPENVPN_CUSTOM_CONFIG=/gluetun/config.ovpn -e OPENVPN_USER=xxxxxx -e OPENVPN_PASSWORD=xxxxxx qmcgaw/gluetun
========================================
========================================
=============== gluetun ================
========================================
=========== Made with ❤ by ============
======= https://github.com/qdm12 =======
========================================
========================================

Running version latest built on 2024-12-27T20:18:46.989Z (commit 61b053f)

🔧 Need help? ☕ Discussion? https://github.com/qdm12/gluetun/discussions/new/choose
🐛 Bug? ✨ New feature? https://github.com/qdm12/gluetun/issues/new/choose
💻 Email? quentin.mcgaw@gmail.com
💰 Help me? https://www.paypal.me/qmcgaw https://github.com/sponsors/qdm12
2025-01-02T19:00:20Z INFO [routing] default route found: interface eth0, gateway 172.16.0.1, assigned IP 172.16.0.2 and family v4
2025-01-02T19:00:20Z INFO [routing] local ethernet link found: eth0
2025-01-02T19:00:20Z INFO [routing] local ipnet found: 172.16.0.0/24
2025-01-02T19:00:20Z INFO [firewall] enabling...
2025-01-02T19:00:20Z INFO [firewall] enabled successfully
2025-01-02T19:00:20Z INFO [storage] creating /gluetun/servers.json with 20776 hardcoded servers
2025-01-02T19:00:20Z INFO Alpine version: 3.20.3
2025-01-02T19:00:20Z INFO OpenVPN 2.5 version: 2.5.10
2025-01-02T19:00:20Z INFO OpenVPN 2.6 version: 2.6.11
2025-01-02T19:00:20Z INFO IPtables version: v1.8.10
2025-01-02T19:00:20Z INFO Settings summary:
├── VPN settings:
|   ├── VPN provider settings:
|   |   ├── Name: custom
|   |   └── Server selection settings:
|   |       ├── VPN type: openvpn
|   |       └── OpenVPN server selection settings:
|   |           ├── Protocol: UDP
|   |           └── Custom configuration file: /gluetun/config.ovpn
|   └── OpenVPN settings:
|       ├── OpenVPN version: 2.6
|       ├── User: [set]
|       ├── Password: [set]
|       ├── Custom configuration file: /gluetun/config.ovpn
|       ├── Network interface: tun0
|       ├── Run OpenVPN as: root
|       └── Verbosity level: 1
├── DNS settings:
|   ├── Keep existing nameserver(s): no
|   ├── DNS server address to use: 127.0.0.1
|   └── DNS over TLS settings:
|       ├── Enabled: yes
|       ├── Update period: every 24h0m0s
|       ├── Upstream resolvers:
|       |   └── cloudflare
|       ├── Caching: yes
|       ├── IPv6: no
|       └── DNS filtering settings:
|           ├── Block malicious: yes
|           ├── Block ads: no
|           ├── Block surveillance: no
|           └── Blocked IP networks:
|               ├── 127.0.0.1/8
|               ├── 10.0.0.0/8
|               ├── 172.16.0.0/12
|               ├── 192.168.0.0/16
|               ├── 169.254.0.0/16
|               ├── ::1/128
|               ├── fc00::/7
|               ├── fe80::/10
|               ├── ::ffff:127.0.0.1/104
|               ├── ::ffff:10.0.0.0/104
|               ├── ::ffff:169.254.0.0/112
|               ├── ::ffff:172.16.0.0/108
|               └── ::ffff:192.168.0.0/112
├── Firewall settings:
|   └── Enabled: yes
├── Log settings:
|   └── Log level: info
├── Health settings:
|   ├── Server listening address: 127.0.0.1:9999
|   ├── Target address: cloudflare.com:443
|   ├── Duration to wait after success: 5s
|   ├── Read header timeout: 100ms
|   ├── Read timeout: 500ms
|   └── VPN wait durations:
|       ├── Initial duration: 6s
|       └── Additional duration: 5s
├── Shadowsocks server settings:
|   └── Enabled: no
├── HTTP proxy settings:
|   └── Enabled: no
├── Control server settings:
|   ├── Listening address: :8000
|   ├── Logging: yes
|   └── Authentication file path: /gluetun/auth/config.toml
├── Storage settings:
|   └── Filepath: /gluetun/servers.json
├── OS Alpine settings:
|   ├── Process UID: 1000
|   └── Process GID: 1000
├── Public IP settings:
|   ├── IP file path: /tmp/gluetun/ip
|   ├── Public IP data base API: ipinfo
|   └── Public IP data backup APIs:
|       ├── ifconfigco
|       ├── ip2location
|       └── cloudflare
└── Version settings:
    └── Enabled: yes
2025-01-02T19:00:21Z INFO [routing] default route found: interface eth0, gateway 172.16.0.1, assigned IP 172.16.0.2 and family v4
2025-01-02T19:00:21Z INFO [routing] adding route for 0.0.0.0/0
2025-01-02T19:00:21Z INFO [firewall] setting allowed subnets...
2025-01-02T19:00:21Z INFO [routing] default route found: interface eth0, gateway 172.16.0.1, assigned IP 172.16.0.2 and family v4
2025-01-02T19:00:21Z INFO TUN device is not available: open /dev/net/tun: no such file or directory; creating it...
2025-01-02T19:00:21Z INFO [dns] using plaintext DNS at address 1.1.1.1
2025-01-02T19:00:21Z INFO [http server] http server listening on [::]:8000
2025-01-02T19:00:21Z INFO [healthcheck] listening on 127.0.0.1:9999
2025-01-02T19:00:21Z INFO [firewall] allowing VPN connection...
2025-01-02T19:00:21Z INFO [openvpn] DEPRECATED OPTION: --cipher set to 'AES-256-CBC' but missing in --data-ciphers (AES-256-GCM:AES-128-GCM:CHACHA20-POLY1305). OpenVPN ignores --cipher for cipher negotiations. 
2025-01-02T19:00:21Z INFO [openvpn] OpenVPN 2.6.11 x86_64-alpine-linux-musl [SSL (OpenSSL)] [LZO] [LZ4] [EPOLL] [MH/PKTINFO] [AEAD]
2025-01-02T19:00:21Z INFO [openvpn] library versions: OpenSSL 3.3.2 3 Sep 2024, LZO 2.10
2025-01-02T19:00:21Z INFO [openvpn] TCP/UDP: Preserving recently used remote address: [AF_INET]185.107.94.249:1194
2025-01-02T19:00:21Z INFO [openvpn] UDPv4 link local: (not bound)
2025-01-02T19:00:21Z INFO [openvpn] UDPv4 link remote: [AF_INET]185.107.94.249:1194
2025-01-02T19:00:26Z INFO [openvpn] [vpn-nl.premiumize.me] Peer Connection Initiated with [AF_INET]185.107.94.249:1194
2025-01-02T19:00:26Z ERROR [openvpn] AUTH: Received control message: AUTH_FAILED

Your credentials might be wrong 🤨


2025-01-02T19:00:26Z INFO [openvpn] SIGUSR1[soft,auth-failure] received, process restarting
2025-01-02T19:00:27Z INFO [healthcheck] program has been unhealthy for 6s: restarting VPN (healthcheck error: dialing: dial tcp4: lookup cloudflare.com on 1.1.1.1:53: write udp 172.16.0.2:35123->1.1.1.1:53: write: operation not permitted)
2025-01-02T19:00:27Z INFO [healthcheck] 👉 See https://github.com/qdm12/gluetun-wiki/blob/main/faq/healthcheck.md
2025-01-02T19:00:27Z INFO [healthcheck] DO NOT OPEN AN ISSUE UNLESS YOU READ AND TRIED EACH POSSIBLE SOLUTION
2025-01-02T19:00:27Z INFO [vpn] stopping
2025-01-02T19:00:27Z INFO [vpn] starting
2025-01-02T19:00:27Z INFO [firewall] allowing VPN connection...
2025-01-02T19:00:27Z INFO [openvpn] DEPRECATED OPTION: --cipher set to 'AES-256-CBC' but missing in --data-ciphers (AES-256-GCM:AES-128-GCM:CHACHA20-POLY1305). OpenVPN ignores --cipher for cipher negotiations. 
2025-01-02T19:00:27Z INFO [openvpn] OpenVPN 2.6.11 x86_64-alpine-linux-musl [SSL (OpenSSL)] [LZO] [LZ4] [EPOLL] [MH/PKTINFO] [AEAD]
2025-01-02T19:00:27Z INFO [openvpn] library versions: OpenSSL 3.3.2 3 Sep 2024, LZO 2.10
2025-01-02T19:00:27Z INFO [openvpn] TCP/UDP: Preserving recently used remote address: [AF_INET]185.107.94.249:1194
2025-01-02T19:00:27Z INFO [openvpn] UDPv4 link local: (not bound)
2025-01-02T19:00:27Z INFO [openvpn] UDPv4 link remote: [AF_INET]185.107.94.249:1194
2025-01-02T19:00:27Z INFO [openvpn] [vpn-nl.premiumize.me] Peer Connection Initiated with [AF_INET]185.107.94.249:1194
2025-01-02T19:00:27Z ERROR [openvpn] AUTH: Received control message: AUTH_FAILED

Your credentials might be wrong 🤨


2025-01-02T19:00:27Z INFO [openvpn] SIGUSR1[soft,auth-failure] received, process restarting
^C
2025-01-02T19:00:29Z WARN Caught OS signal interrupt, shutting down
2025-01-02T19:00:29Z INFO updater ticker: terminated ✔
2025-01-02T19:00:29Z INFO dns ticker: terminated ✔
2025-01-02T19:00:29Z INFO http server: terminated ✔
2025-01-02T19:00:29Z INFO control: terminated ✔
2025-01-02T19:00:29Z INFO updater: terminated ✔
2025-01-02T19:00:29Z INFO tickers: terminated ✔
2025-01-02T19:00:29Z WARN HTTP health server: goroutine shutdown timed out: after 400ms ⚠
2025-01-02T19:00:29Z INFO vpn: terminated ✔
2025-01-02T19:00:29Z INFO shadowsocks proxy: terminated ✔
2025-01-02T19:00:29Z INFO http proxy: terminated ✔
2025-01-02T19:00:29Z INFO dns: terminated ✔
2025-01-02T19:00:29Z INFO other: terminated ✔
2025-01-02T19:00:29Z INFO [routing] routing cleanup...
2025-01-02T19:00:29Z INFO [routing] default route found: interface eth0, gateway 172.16.0.1, assigned IP 172.16.0.2 and family v4
2025-01-02T19:00:29Z INFO [routing] deleting route for 0.0.0.0/0
2025-01-02T19:00:29Z WARN Shutdown failed: ordered shutdown timed out: HTTP health server: goroutine shutdown timed out: after 400ms

Credentials are absolutly correct.

on my desktop

❱sudo openvpn --config Downloads/vpn-nl.premiumize.me.ovpn --auth-user-pass credentials.txt
[sudo] password for greg: 
2025-01-02 19:12:02 DEPRECATED OPTION: --cipher set to 'AES-256-CBC' but missing in --data-ciphers (AES-256-GCM:AES-128-GCM:CHACHA20-POLY1305). OpenVPN ignores --cipher for cipher negotiations. 
2025-01-02 19:12:02 Note: Kernel support for ovpn-dco missing, disabling data channel offload.
2025-01-02 19:12:02 WARNING: file 'credentials.txt' is group or others accessible
2025-01-02 19:12:02 OpenVPN 2.6.12 [git:makepkg/038a94bae57a446c+] x86_64-pc-linux-gnu [SSL (OpenSSL)] [LZO] [LZ4] [EPOLL] [PKCS11] [MH/PKTINFO] [AEAD] [DCO] built on Jul 18 2024
2025-01-02 19:12:02 library versions: OpenSSL 3.4.0 22 Oct 2024, LZO 2.10
2025-01-02 19:12:02 DCO version: N/A
2025-01-02 19:12:02 TCP/UDP: Preserving recently used remote address: [AF_INET]185.107.94.249:1194
2025-01-02 19:12:02 Socket Buffers: R=[212992->212992] S=[212992->212992]
2025-01-02 19:12:02 UDPv4 link local: (not bound)
2025-01-02 19:12:02 UDPv4 link remote: [AF_INET]185.107.94.249:1194
2025-01-02 19:12:02 TLS: Initial packet from [AF_INET]185.107.94.249:1194, sid=a1043458 b20a4cc6
2025-01-02 19:12:02 WARNING: this configuration may cache passwords in memory -- use the auth-nocache option to prevent this
2025-01-02 19:12:02 VERIFY OK: depth=2, O=Secure Services, CN=Root X1
2025-01-02 19:12:02 VERIFY OK: depth=1, O=Secure Services, CN=Intermediate X5
2025-01-02 19:12:02 VERIFY X509NAME OK: CN=vpn-nl.premiumize.me
2025-01-02 19:12:02 VERIFY OK: depth=0, CN=vpn-nl.premiumize.me
2025-01-02 19:12:03 Control Channel: TLSv1.3, cipher TLSv1.3 TLS_AES_256_GCM_SHA384, peer certificate: 2048 bits RSA, signature: RSA-SHA256, peer temporary key: 253 bits X25519
2025-01-02 19:12:03 [vpn-nl.premiumize.me] Peer Connection Initiated with [AF_INET]185.107.94.249:1194
2025-01-02 19:12:03 TLS: move_session: dest=TM_ACTIVE src=TM_INITIAL reinit_src=1
2025-01-02 19:12:03 TLS: tls_multi_process: initial untrusted session promoted to trusted
2025-01-02 19:12:03 PUSH: Received control message: 'PUSH_REPLY,redirect-gateway def1,route-ipv6 ::/3,route-ipv6 2000::/4,route-ipv6 3000::/4,route-ipv6 fc00::/7,dhcp-option DNS 1.1.1.1,dhcp-option DNS 1.0.0.1,block-outside-dns,tun-ipv6,route-gateway 10.8.0.1,topology subnet,ping 50,ping-restart 120,ifconfig-ipv6 fde7:523e:dd18:bf22::1032/64 fde7:523e:dd18:bf22::1,ifconfig 10.8.0.52 255.255.0.0,peer-id 69,cipher AES-256-GCM,protocol-flags cc-exit tls-ekm dyn-tls-crypt,tun-mtu 1500'
2025-01-02 19:12:03 Unrecognized option or missing or extra parameter(s) in [PUSH-OPTIONS]:8: block-outside-dns (2.6.12)
2025-01-02 19:12:03 OPTIONS IMPORT: --ifconfig/up options modified
2025-01-02 19:12:03 OPTIONS IMPORT: route options modified
2025-01-02 19:12:03 OPTIONS IMPORT: route-related options modified
2025-01-02 19:12:03 OPTIONS IMPORT: --ip-win32 and/or --dhcp-option options modified
2025-01-02 19:12:03 OPTIONS IMPORT: tun-mtu set to 1500
2025-01-02 19:12:03 net_route_v4_best_gw query: dst 0.0.0.0
2025-01-02 19:12:03 net_route_v4_best_gw result: via 192.168.1.1 dev wlp89s0
2025-01-02 19:12:03 ROUTE_GATEWAY 192.168.1.1/255.255.255.0 IFACE=wlp89s0 HWADDR=d0:12:55:2c:19:94
2025-01-02 19:12:03 GDG6: remote_host_ipv6=n/a
2025-01-02 19:12:03 net_route_v6_best_gw query: dst ::
2025-01-02 19:12:03 sitnl_send: rtnl: generic error (-101): Network is unreachable
2025-01-02 19:12:03 ROUTE6: default_gateway=UNDEF
2025-01-02 19:12:03 TUN/TAP device tun0 opened
2025-01-02 19:12:03 net_iface_mtu_set: mtu 1500 for tun0
2025-01-02 19:12:03 net_iface_up: set tun0 up
2025-01-02 19:12:03 net_addr_v4_add: 10.8.0.52/16 dev tun0
2025-01-02 19:12:03 net_iface_mtu_set: mtu 1500 for tun0
2025-01-02 19:12:03 net_iface_up: set tun0 up
2025-01-02 19:12:03 net_addr_v6_add: fde7:523e:dd18:bf22::1032/64 dev tun0
2025-01-02 19:12:03 net_route_v4_add: 185.107.94.249/32 via 192.168.1.1 dev [NULL] table 0 metric -1
2025-01-02 19:12:03 net_route_v4_add: 0.0.0.0/1 via 10.8.0.1 dev [NULL] table 0 metric -1
2025-01-02 19:12:03 net_route_v4_add: 128.0.0.0/1 via 10.8.0.1 dev [NULL] table 0 metric -1
2025-01-02 19:12:03 add_route_ipv6(::/3 -> fde7:523e:dd18:bf22::1 metric -1) dev tun0
2025-01-02 19:12:03 net_route_v6_add: ::/3 via :: dev tun0 table 0 metric -1
2025-01-02 19:12:03 add_route_ipv6(2000::/4 -> fde7:523e:dd18:bf22::1 metric -1) dev tun0
2025-01-02 19:12:03 net_route_v6_add: 2000::/4 via :: dev tun0 table 0 metric -1
2025-01-02 19:12:03 add_route_ipv6(3000::/4 -> fde7:523e:dd18:bf22::1 metric -1) dev tun0
2025-01-02 19:12:03 net_route_v6_add: 3000::/4 via :: dev tun0 table 0 metric -1
2025-01-02 19:12:03 add_route_ipv6(fc00::/7 -> fde7:523e:dd18:bf22::1 metric -1) dev tun0
2025-01-02 19:12:03 net_route_v6_add: fc00::/7 via :: dev tun0 table 0 metric -1
2025-01-02 19:12:03 Initialization Sequence Completed
2025-01-02 19:12:03 Data Channel: cipher 'AES-256-GCM', peer-id: 69
2025-01-02 19:12:03 Timers: ping 50, ping-restart 120
2025-01-02 19:12:03 Protocol options: protocol-flags cc-exit tls-ekm dyn-tls-crypt
2025-01-02 19:12:05 read UDPv4 [EMSGSIZE Path-MTU=1480|EMSGSIZE Path-MTU=1480]: Message too long (fd=3,code=90)
^C2025-01-02 19:13:48 net_route_v4_del: 185.107.94.249/32 via 192.168.1.1 dev [NULL] table 0 metric -1
2025-01-02 19:13:48 net_route_v4_del: 0.0.0.0/1 via 10.8.0.1 dev [NULL] table 0 metric -1
2025-01-02 19:13:48 net_route_v4_del: 128.0.0.0/1 via 10.8.0.1 dev [NULL] table 0 metric -1
2025-01-02 19:13:48 delete_route_ipv6(::/3)
2025-01-02 19:13:48 net_route_v6_del: ::/3 via :: dev tun0 table 0 metric -1
2025-01-02 19:13:48 delete_route_ipv6(2000::/4)
2025-01-02 19:13:48 net_route_v6_del: 2000::/4 via :: dev tun0 table 0 metric -1
2025-01-02 19:13:48 delete_route_ipv6(3000::/4)
2025-01-02 19:13:48 net_route_v6_del: 3000::/4 via :: dev tun0 table 0 metric -1
2025-01-02 19:13:48 delete_route_ipv6(fc00::/7)
2025-01-02 19:13:48 net_route_v6_del: fc00::/7 via :: dev tun0 table 0 metric -1
2025-01-02 19:13:48 Closing TUN/TAP interface
2025-01-02 19:13:48 net_addr_v4_del: 10.8.0.52 dev tun0
2025-01-02 19:13:48 net_addr_v6_del: fde7:523e:dd18:bf22::1032/64 dev tun0
2025-01-02 19:13:49 SIGINT[hard,] received, process exiting

on other terminal:


❱curl ifconfig.me
2a00:1768:6001:1e::4⏎                                                                                                                                                      
⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼ /home/greg ⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼
❱curl -4 ifconfig.me

185.107.94.249⏎                                                                                                                                                            
⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼ /home/greg ⎼⎼⎼⎼⎼⎼⎼⎼⎼⎼
❱curl ipinfo.io

{
  "ip": "185.107.94.249",
  "city": "Roosendaal",
  "region": "North Brabant",
  "country": "NL",
  "loc": "51.5308,4.4653",
  "org": "AS43350 NForce Entertainment B.V.",
  "postal": "4701",
  "timezone": "Europe/Amsterdam",
  "readme": "https://ipinfo.io/missingauth"
}⏎                                                                                                                                                                         

I am prepared to give away my credentials for a while if anyone would take up the challenge.

Please just say.

This should be the proper way to do gluetun with a custom openvpn. Sub in the ports you need.

services:
  gluetun:
    container_name: gluetun
    image: qmcgaw/gluetun:latest
    cap_add:
      - NET_ADMIN
    ports:
      - 8888:8888/tcp
      - 8388:8388/tcp
      - 8388:8388/udp
      - 10095:10095
      - 6881:6881
      - 6881:6881/udp
    devices:
      - /dev/net/tun:/dev/net/tun
    volumes:
      - ./PATHTOCONFIG/yourovpnconfig.conf:/gluetun/custom.conf:ro
    environment:
      - VPN_SERVICE_PROVIDER=custom
      - VPN_TYPE=openvpn
      - OPENVPN_CUSTOM_CONFIG=/gluetun/custom.conf
    restart: unless-stopped

whats ./PATHTOCONFIG ?

- ./PATHTOCONFIG/yourovpnconfig.conf:/gluetun/custom.conf:ro

my volumes: look like this

volumes:
      - /mnt/basepool/aplications/gluetun:/config
      - /mnt/basepool/aplications/gluetun/config.ovpn:/config/config.ovpn

but its reading the file .ovpn file fine.

This is my setup.

This is what I already have, it’s just a tiny bit rearranged but nothing consequential.

services:
  gluetun:
    image: qmcgaw/gluetun
    container_name: gluetun
    cap_add:
      - NET_ADMIN
    devices:
      - /dev/net/tun:/dev/net/tun
    ports:
      - 8888:8888/tcp # HTTP proxy
      - 8388:8388/tcp # Shadowsocks
      - 8388:8388/udp # Shadowsocks
      - 8080:8080 # qBittorrent WebUI
      - 6881:6881 # Torrenting port
      - 6881:6881/udp # Torrenting port
      - 10095:10095
    volumes:
      - /mnt/basepool/aplications/gluetun:/config
      - /mnt/basepool/aplications/gluetun/config.ovpn:/config/config.ovpn
    environment:
      - VPN_TYPE=openvpn
      - PUID=3003
      - PGID=3003
      - FIREWALL_VPN_INPUT_PORTS=8080,6881
      - VPN_SERVICE_PROVIDER=custom
      - OPENVPN_CUSTOM_CONFIG=/config/config.ovpn
    dns:
      - 1.1.1.1
      - 1.0.0.1
    restart: unless-stopped

my vpn file called config.ovpn

jack@TruenasScale ~ $ cat /mnt/basepool/aplications/gluetun/config.ovpn 
remote 185.107.94.249
verify-x509-name CN=vpn-nl.premiumize.me
auth-user-pass /config/credentials.txt
client
dev tun
proto udp
cipher AES-256-CBC
resolv-retry infinite
nobind
persist-key
persist-tun
mute-replay-warnings
verb 3
reneg-sec 0
setenv CLIENT_CERT 0
ignore-unknown-option block-outside-dns
<ca>
-----BEGIN CERTIFICATE-----
MIIFJTCCAw2gAwIBAgIRAPAmbQRNE+PBqvFyFG8GOSIwDQYJKoZIhvcNAQELBQAw
LDEYMBYGA1UECgwPU2VjdXJlIFNlcnZpY2VzMRAwDgYDVQQDDAdSb290IFgxMB4X
DTIxMDEwNDE1MjEwM1oXDTQwMTIzMDE1MjEwM1owLDEYMBYGA1UECgwPU2VjdXJl
IFNlcnZpY2VzMRAwDgYDVQQDDAdSb290IFgxMIICIjANBgkqhkiG9w0BAQEFAAOC
Ag8AMIICCgKCAgEAvuhFcbO0Y5SXBr+h/XU1sPXo/OSjN4W32jzVZ3jmkqA2nH5D
dI5XYHYB9JkW23K37zOlvOWj9J3HiV6WYk0uqQ3cpqDMnIpi1MJCtSRxiaD7LTNO
XrvLpsREq9Vf+lN+zxFxhINv3W4jUyfx5zIjPyjY+vFgH5G56b12EeLKFLYUWwgF
9vTicXJvlV1h+TJVF8wZ5DugrgNZhSZ6QZzda0Zdu1dCwZOafd1GGDWPubgZ8enF
b9gWPGZmS59ZvlLsLQmtLvCEegELzRR5G/OI1CIntcImcKO9ZDdWP+HmqJ4Ss7Ng

it is set atm to have the auth-user-pass /config/cred.txt in the .ovpn file and a

ack@TruenasScale ~ $ cat /mnt/basepool/aplications/gluetun/credentials.txt 
USERNAME
PASSWORD
jack@TruenasScale ~ $ 

the output

───────────────────────────────────────
qbittorrent  | 
qbittorrent  |       ██╗     ███████╗██╗ ██████╗
qbittorrent  |       ██║     ██╔════╝██║██╔═══██╗
qbittorrent  |       ██║     ███████╗██║██║   ██║
qbittorrent  |       ██║     ╚════██║██║██║   ██║
qbittorrent  |       ███████╗███████║██║╚██████╔╝
qbittorrent  |       ╚══════╝╚══════╝╚═╝ ╚═════╝
qbittorrent  | 
qbittorrent  |    Brought to you by linuxserver.io
qbittorrent  | ───────────────────────────────────────
qbittorrent  | 
qbittorrent  | To support LSIO projects visit:
qbittorrent  | https://www.linuxserver.io/donate/
qbittorrent  | 
qbittorrent  | ───────────────────────────────────────
qbittorrent  | GID/UID
qbittorrent  | ───────────────────────────────────────
qbittorrent  | 
qbittorrent  | User UID:    3003
qbittorrent  | User GID:    3003
qbittorrent  | ───────────────────────────────────────
qbittorrent  | Linuxserver.io version: 5.0.3-r0-ls371
qbittorrent  | Build-date: 2025-01-01T22:48:48+00:00
qbittorrent  | ───────────────────────────────────────
qbittorrent  |     
qbittorrent  | [custom-init] No custom files found, skipping...
qbittorrent  | WebUI will be started shortly after internal preparations. Please wait...
gluetun      | 2025-01-03T00:07:54Z INFO [storage] creating /gluetun/servers.json with 20776 hardcoded servers
qbittorrent  | 
qbittorrent  | ******** Information ********
qbittorrent  | To control qBittorrent, access the WebUI at: http://localhost:8080
qbittorrent  | The WebUI administrator username is: admin
qbittorrent  | The WebUI administrator password was not set. A temporary password is provided for this session: Z8QmXk37z
qbittorrent  | You should set your own password in program preferences.
gluetun      | 2025-01-03T00:07:55Z INFO Alpine version: 3.20.3
gluetun      | 2025-01-03T00:07:55Z INFO OpenVPN 2.5 version: 2.5.10
gluetun      | 2025-01-03T00:07:55Z INFO OpenVPN 2.6 version: 2.6.11
gluetun      | 2025-01-03T00:07:55Z INFO IPtables version: v1.8.10
gluetun      | 2025-01-03T00:07:55Z INFO Settings summary:
gluetun      | ├── VPN settings:
gluetun      | |   ├── VPN provider settings:
gluetun      | |   |   ├── Name: custom
gluetun      | |   |   └── Server selection settings:
gluetun      | |   |       ├── VPN type: openvpn
gluetun      | |   |       └── OpenVPN server selection settings:
gluetun      | |   |           ├── Protocol: UDP
gluetun      | |   |           └── Custom configuration file: /config/config.ovpn
gluetun      | |   └── OpenVPN settings:
gluetun      | |       ├── OpenVPN version: 2.6
gluetun      | |       ├── User: [not set]
gluetun      | |       ├── Password: [not set]
gluetun      | |       ├── Custom configuration file: /config/config.ovpn
gluetun      | |       ├── Network interface: tun0
gluetun      | |       ├── Run OpenVPN as: root
gluetun      | |       └── Verbosity level: 1
gluetun      | ├── DNS settings:
gluetun      | |   ├── Keep existing nameserver(s): no
gluetun      | |   ├── DNS server address to use: 127.0.0.1
gluetun      | |   └── DNS over TLS settings:
gluetun      | |       ├── Enabled: yes
gluetun      | |       ├── Update period: every 24h0m0s
gluetun      | |       ├── Upstream resolvers:
gluetun      | |       |   └── cloudflare
gluetun      | |       ├── Caching: yes
gluetun      | |       ├── IPv6: no
gluetun      | |       └── DNS filtering settings:
gluetun      | |           ├── Block malicious: yes
gluetun      | |           ├── Block ads: no
gluetun      | |           ├── Block surveillance: no
gluetun      | |           └── Blocked IP networks:
gluetun      | |               ├── 127.0.0.1/8
gluetun      | |               ├── 10.0.0.0/8
gluetun      | |               ├── 172.16.0.0/12
gluetun      | |               ├── 192.168.0.0/16
gluetun      | |               ├── 169.254.0.0/16
gluetun      | |               ├── ::1/128
gluetun      | |               ├── fc00::/7
gluetun      | |               ├── fe80::/10
gluetun      | |               ├── ::ffff:127.0.0.1/104
gluetun      | |               ├── ::ffff:10.0.0.0/104
gluetun      | |               ├── ::ffff:169.254.0.0/112
gluetun      | |               ├── ::ffff:172.16.0.0/108
gluetun      | |               └── ::ffff:192.168.0.0/112
gluetun      | ├── Firewall settings:
gluetun      | |   ├── Enabled: yes
gluetun      | |   └── VPN input ports:
gluetun      | |       ├── 8080
gluetun      | |       └── 6881
gluetun      | ├── Log settings:
gluetun      | |   └── Log level: info
gluetun      | ├── Health settings:
gluetun      | |   ├── Server listening address: 127.0.0.1:9999
gluetun      | |   ├── Target address: cloudflare.com:443
gluetun      | |   ├── Duration to wait after success: 5s
gluetun      | |   ├── Read header timeout: 100ms
gluetun      | |   ├── Read timeout: 500ms
gluetun      | |   └── VPN wait durations:
gluetun      | |       ├── Initial duration: 6s
gluetun      | |       └── Additional duration: 5s
gluetun      | ├── Shadowsocks server settings:
gluetun      | |   └── Enabled: no
gluetun      | ├── HTTP proxy settings:
gluetun      | |   └── Enabled: no
gluetun      | ├── Control server settings:
gluetun      | |   ├── Listening address: :8000
gluetun      | |   ├── Logging: yes
gluetun      | |   └── Authentication file path: /gluetun/auth/config.toml
gluetun      | ├── Storage settings:
gluetun      | |   └── Filepath: /gluetun/servers.json
gluetun      | ├── OS Alpine settings:
gluetun      | |   ├── Process UID: 3003
gluetun      | |   └── Process GID: 3003
gluetun      | ├── Public IP settings:
gluetun      | |   ├── IP file path: /tmp/gluetun/ip
gluetun      | |   ├── Public IP data base API: ipinfo
gluetun      | |   └── Public IP data backup APIs:
gluetun      | |       ├── ifconfigco
gluetun      | |       ├── ip2location
gluetun      | |       └── cloudflare
gluetun      | └── Version settings:
gluetun      |     └── Enabled: yes
gluetun      | 2025-01-03T00:07:55Z INFO [routing] default route found: interface eth0, gateway 172.16.6.1, assigned IP 172.16.6.2 and family v4
gluetun      | 2025-01-03T00:07:55Z INFO [routing] adding route for 0.0.0.0/0
gluetun      | 2025-01-03T00:07:55Z INFO [firewall] setting allowed subnets...
gluetun      | 2025-01-03T00:07:55Z INFO [routing] default route found: interface eth0, gateway 172.16.6.1, assigned IP 172.16.6.2 and family v4
gluetun      | 2025-01-03T00:07:55Z INFO [dns] using plaintext DNS at address 1.1.1.1
gluetun      | 2025-01-03T00:07:55Z INFO [http server] http server listening on [::]:8000
gluetun      | 2025-01-03T00:07:55Z INFO [healthcheck] listening on 127.0.0.1:9999
gluetun      | 2025-01-03T00:07:55Z INFO [firewall] allowing VPN connection...
gluetun      | 2025-01-03T00:07:55Z INFO [openvpn] DEPRECATED OPTION: --cipher set to 'AES-256-CBC' but missing in --data-ciphers (AES-256-GCM:AES-128-GCM:CHACHA20-POLY1305). OpenVPN ignores --cipher for cipher negotiations. 
gluetun      | 2025-01-03T00:07:55Z ERROR [openvpn] No client-side authentication method is specified.  You must use either --cert/--key, --pkcs12, or --auth-user-pass
gluetun      | 2025-01-03T00:07:55Z INFO [openvpn] Use --help for more information.
gluetun      | 2025-01-03T00:07:55Z ERROR [vpn] exit status 1
gluetun      | 2025-01-03T00:07:55Z INFO [vpn] retrying in 15s
qbittorrent  | Connection to localhost (::1) 8080 port [tcp/http-alt] succeeded!
qbittorrent  | [ls.io-init] done.
gluetun      | 2025-01-03T00:08:01Z INFO [healthcheck] program has been unhealthy for 6s: restarting VPN (healthcheck error: dialing: dial tcp4: lookup cloudflare.com on 1.1.1.1:53: write udp 172.16.6.2:58034->1.1.1.1:53: write: operation not permitted)
gluetun      | 2025-01-03T00:08:01Z INFO [healthcheck] 👉 See https://github.com/qdm12/gluetun-wiki/blob/main/faq/healthcheck.md
gluetun      | 2025-01-03T00:08:01Z INFO [healthcheck] DO NOT OPEN AN ISSUE UNLESS YOU READ AND TRIED EACH POSSIBLE SOLUTION
gluetun      | 2025-01-03T00:08:10Z INFO [firewall] allowing VPN connection...
gluetun      | 2025-01-03T00:08:10Z INFO [openvpn] DEPRECATED OPTION: --cipher set to 'AES-256-CBC' but missing in --data-ciphers (AES-256-GCM:AES-128-GCM:CHACHA20-POLY1305). OpenVPN ignores --cipher for cipher negotiations. 
gluetun      | 2025-01-03T00:08:10Z ERROR [openvpn] No client-side authentication method is specified.  You must use either --cert/--key, --pkcs12, or --auth-user-pass
gluetun      | 2025-01-03T00:08:10Z INFO [openvpn] Use --help for more information.
gluetun      | 2025-01-03T00:08:10Z ERROR [vpn] exit status 1
gluetun      | 2025-01-03T00:08:10Z INFO [vpn] retrying in 30s
gluetun      | 2025-01-03T00:08:12Z INFO [healthcheck] program has been unhealthy for 11s: restarting VPN (healthcheck error: dialing: dial tcp4: lookup cloudflare.com on 1.1.1.1:53: write udp 172.16.6.2:54986->1.1.1.1:53: write: operation not permitted)
gluetun      | 2025-01-03T00:08:12Z INFO [healthcheck] 👉 See https://github.com/qdm12/gluetun-wiki/blob/main/faq/healthcheck.md
gluetun      | 2025-01-03T00:08:12Z INFO [healthcheck] DO NOT OPEN AN ISSUE UNLESS YOU READ AND TRIED EACH POSSIBLE SOLUTION
gluetun      | 2025-01-03T00:08:28Z INFO [healthcheck] program has been unhealthy for 16s: restarting VPN (healthcheck error: dialing: dial tcp4: lookup cloudflare.com on 1.1.1.1:53: write udp 172.16.6.2:56829->1.1.1.1:53: write: operation not permitted)
gluetun      | 2025-01-03T00:08:28Z INFO [healthcheck] 👉 See https://github.com/qdm12/gluetun-wiki/blob/main/faq/healthcheck.md
gluetun      | 2025-01-03T00:08:28Z INFO [healthcheck] DO NOT OPEN AN ISSUE UNLESS YOU READ AND TRIED EACH POSSIBLE SOLUTION
gluetun      | 
gluetun      | 2025-01-03T00:08:29Z WARN Caught OS signal terminated, shutting down
gluetun      | 2025-01-03T00:08:29Z INFO dns ticker: terminated ✔️
gluetun      | 2025-01-03T00:08:29Z INFO updater ticker: terminated ✔️
gluetun      | 2025-01-03T00:08:29Z INFO http server: terminated ✔️
gluetun      | 2025-01-03T00:08:29Z INFO control: terminated ✔️
gluetun      | 2025-01-03T00:08:29Z INFO updater: terminated ✔️
gluetun      | 2025-01-03T00:08:29Z INFO tickers: terminated ✔️
qbittorrent  | Catching signal: SIGTERM
qbittorrent  | Exiting cleanly
gluetun      | 2025-01-03T00:08:29Z WARN HTTP health server: goroutine shutdown timed out: after 400ms ⚠️
gluetun      | 2025-01-03T00:08:29Z INFO vpn: terminated ✔️
gluetun      | 2025-01-03T00:08:29Z INFO shadowsocks proxy: terminated ✔️
gluetun      | 2025-01-03T00:08:29Z INFO dns: terminated ✔️
gluetun      | 2025-01-03T00:08:29Z INFO http proxy: terminated ✔️
gluetun      | 2025-01-03T00:08:29Z INFO other: terminated ✔️
gluetun      | 2025-01-03T00:08:29Z INFO [routing] routing cleanup...
gluetun      | 2025-01-03T00:08:29Z INFO [routing] default route found: interface eth0, gateway 172.16.6.1, assigned IP 172.16.6.2 and family v4
gluetun      | 2025-01-03T00:08:29Z INFO [routing] deleting route for 0.0.0.0/0
gluetun      | 2025-01-03T00:08:29Z WARN Shutdown failed: ordered shutdown timed out: HTTP health server: goroutine shutdown timed out: after 400ms
gluetun exited with code 0
gluetun exited with code 1
qbittorrent exited with code 0

I have also tried putting the credentials in as env’s in the little box below the yaml input box and removing all mention of the credentials.txt file.

From their documentation, the environment section of you compose should have:

        environment:
            - VPN_SERVICE_PROVIDER=custom
            - OPENVPN_CUSTOM_CONFIG=/gluetun/custom.conf
            - OPENVPN_USER=youruser
            - OPENVPN_PASSWORD=yourpassword

Substitute your .conf file

Hi, i managed to get it working. The credentials problem i have no idea why but i rebooted the server in the end and it just worked. I did have a few problems after that with MTU being wrong size and the webui port not being exposed to the lan but it look slike its working.

Many thx for your help :smile: it is highly appreciated.