You may only need the environment or the command-line parameter to force Discord to use a proxy. It doesn't hurt to use both
So if you're behind a firewall and need to go through, e.g. an SSH dynamic port forward (a SOCKS5 channel inside an SSH session) you can use the following:
$ nohup ssh -D1080 proxy_server &
$ http_proxy=socks5://127.0.0.1:1080 https_proxy=socks5://127.0.0.1:1080 /opt/Discord/Discord --proxy-server="socks5://127.0.0.1:1080"
If you use some window manager in Xorg and it uses the .desktop
style launch configurations (Xfce and probably others) using the following will accomplish the same thing for the context-menu / button launch:
$ cat .local/share/applications/discord.desktop
[Desktop Entry]
Name=Discord
StartupWMClass=discord
Comment=All-in-one voice and text chat for gamers that's free, secure, and works on both your desktop and phone.
GenericName=Internet Messenger
Exec=env http_proxy=socks5://127.0.0.1:1080 https_proxy=socks5://127.0.0.1:1080 /opt/Discord/Discord --proxy-server="socks5://127.0.0.1:1080"
Icon=discord
Type=Application
Categories=Network;InstantMessaging;
Path=/tmp
The proxy URI can also be http://
, https://
and possibly socks4://
, socks4a://
or socks5h://
though I have not tested these
Is there any way to ask discord to NOT use a proxy on Linux? I have a proxy defined at the system level (in gnome, I think). That proxy works perfectly for web browsing. When I first start the browser I do have to log in to the proxy. The proxy definition points to a PAC script, and that PAC script tells the browser when to connect directly and when to use the proxy.
I am not allowed to remove the proxy. It is a work requirement. I am trying to connect to a work-related discord server.
So what I want to know is how to tell DIscord not to use the proxy. Discord won't even start, with error net::ERR_TUNNEL_CONNECTION_FAILED
There are no environment variables set for the proxy. I don't know how gnome is communicating the proxy information to discord. I'm running Ubuntu 20.04.