qdm12 / gluetun

VPN client in a thin Docker container for multiple VPN providers, written in Go, and using OpenVPN or Wireguard, DNS over TLS, with a few proxy servers built-in.
https://hub.docker.com/r/qmcgaw/gluetun
MIT License
6.77k stars 333 forks source link

Bug: Container logs show invalid city, but lists the city that I chose as a valid chioce #2029

Open kyle-mcknight opened 6 months ago

kyle-mcknight commented 6 months ago

Is this urgent?

No

Host OS

Windows/WSL2

CPU arch

x86_64

VPN service provider

ExpressVPN

What are you using to run the container

docker-compose

What is the version of Gluetun

Running version latest built on 2023-12-22T09:42:18.243Z (commit f8da1e7)

What's the problem 🤔

I am attempting to set the SERVER_COUNTRY to USA and the SERVER_CITIES to valid values. The container doesn't start and prints an error that one of the cities is not valid, however, all of the cities I've listed are in the json file, they are printed as valid values in the container logs when the error occurs, and they are printed when using the docker run command on the running glueton container to see the list of servers.

Share your logs (at least 10 lines)

2024-01-02 07:15:11 2024-01-02T12:15:11Z INFO [routing] default route found: interface eth0, gateway 172.26.0.1, assigned IP 172.26.0.2 and family v4
2024-01-02 07:15:11 2024-01-02T12:15:11Z INFO [routing] local ethernet link found: eth0
2024-01-02 07:15:11 2024-01-02T12:15:11Z INFO [routing] local ipnet found: 172.26.0.0/16
2024-01-02 07:15:11 2024-01-02T12:15:11Z INFO [firewall] enabling...
2024-01-02 07:15:11 2024-01-02T12:15:11Z INFO [firewall] enabled successfully
2024-01-02 07:15:12 2024-01-02T12:15:12Z INFO [storage] merging by most recent 17685 hardcoded servers and 17685 servers read from /gluetun/servers.json
2024-01-02 07:15:12 2024-01-02T12:15:12Z ERROR VPN settings: provider settings: server selection: for VPN service provider expressvpn: the city specified is not valid: value is not one of the possible choices: value , choices available are Amsterdam, Atlanta, Barcelona, Bosnia And Herzegovina, Brisbane, CBD, Chicago, Cosenza, Costa Rica, Czech Republic, Dallas, Denver, Docklands, Frankfurt, Hong Kong, Isle Of Man, Jurong, Kawasaki, London, Los Angeles, Madrid, Marina Bay, Melbourne, Miami, Milan, Montreal, New Jersey, New York, New Zealand, North Macedonia, Nuremberg, Paris, Perth, Philippines Via Singapore, Rotterdam, Salt Lake City, San Francisco, Seattle, South Africa, South Korea, Sri Lanka, Strasbourg, Sydney, Tampa, The Hague, Tokyo, Toronto, Washington DC

Share your configuration

version: "3"
services:
  gluetun:
    image: qmcgaw/gluetun
    container_name: glueton
    cap_add:
      - NET_ADMIN
    volumes:
      - glueton-config:/glueton
    environment:
      - UPDATE_PERIOD=24
      - VPN_SERVICE_PROVIDER=expressvpn
      - OPENVPN_USER=####
      - OPENVPN_PASSWORD=####
      - SERVER_COUNTRIES=USA
      - SERVER_CITIES=Chicago,Dallas,Atlanta

  glueton-config:
    driver_opts:
      type: cifs
      device: "//Banana/Media/appdata/glueton"
ottomatic42 commented 6 months ago

I also have the same issue. Using express VPN

JardynV commented 4 months ago

Experiencing the same issue using iVPN

docker run -it --rm --cap-add=NET_ADMIN -e VPN_SERVICE_PROVIDER=ivpn -e VPN_TYPE=openvpn -e OPENVPN_USER=-REMOVED- -e SERVER_COUNTRIES='United States' -e SERVER_CITIES='Ashburn' qmcgaw/gluetun

2024-02-12T14:27:54Z INFO [storage] creating /gluetun/servers.json with 17743 hardcoded servers 2024-02-12T14:27:54Z ERROR VPN settings: provider settings: server selection: for VPN service provider ivpn: the city specified is not valid: value is not one of the possible choices: value ashburn, choices available are Amsterdam, Ashburn, VA, Atlanta, GA, Belgrade, Bratislava, Brussels, Bucharest, Budapest, Chicago, IL, Copenhagen, Dallas, TX, Franca, Frankfurt, Helsinki, Holon, Tel Aviv, Hong Kong, Kharkiv, Kuala Lumpur, Las Vegas, NV, Lisbon, London, Los Angeles, CA, Luxembourg, Madrid, Manchester, Miami, FL, Milan, Montreal, New Jersey, NJ, New York, NY, Oslo, Paris, Phoenix, AZ, Prague, Reykjavik, Salt Lake City, UT, Seattle, WA, Singapore, Sofia, Stockholm, Sydney, Taipei, Tokyo, Toronto, Vienna, Warsaw, Zurich 2024-02-12T14:27:54Z INFO Shutdown successful

JardynV commented 4 months ago

Saw previous issues where reverting to 3.4 or 3.4.1 was a temporary solution but had no success.

JardynV commented 4 months ago

A good workaround is using the SERVER_HOSTNAMES= environment variable and pulling the server hostname you want out of the servers.md file for anyone running into this issue.

JardynV commented 4 months ago

But make sure if you take that path you comment or remove BOTH the SERVER_COUNTRIES and SERVER_CITIES variables or it won't utilize the SERVER_HOSTNAMES variable properly