Docker-transmission-openvpn: nginx 502 errors with proxy

Created on 18 Oct 2016  路  5Comments  路  Source: haugene/docker-transmission-openvpn

It seems that when left running for any period of time, the container's state becomes unstable and begins return nginx 502 errors. This also happens for the first 5 minutes after redeployment. Currently have set up to run a shell script to remove and redeploy every hour to avoid this, but problem seems more pronounced in past week.

#!/bin/bash docker stop transmission-openvpn docker rm transmission-openvpn docker stop transmission-proxy docker rm transmission-proxy docker run --privileged -d \ -v /Serve:/Serve \ -v /etc/localtime:/etc/localtime:ro \ -e "OPENVPN_PROVIDER=IVACY" \ -e "OPENVPN_CONFIG=US-UDP" \ -e "OPENVPN_USERNAME=AzureDiamond" \ -e "OPENVPN_PASSWORD=hunter2" \ -e "LOCAL_NETWORK=192.168.1.1/40" \ -e "TRANSMISSION_UMASK=0" \ -e "TRANSMISSION_SPEED_LIMIT_UP=35" \ -e "TRANSMISSION_UPLOAD_LIMIT=35" \ -e "TRANSMISSION_SPEED_LIMIT_UP_ENABLED=true" \ -e "TRANSMISSION_UPLOAD_LIMIT_ENABLED=true" \ -e "TRANSMISSION_DOWNLOAD_DIR=/Serve/Completed" \ -p 9091:9091 \ --dns 8.8.8.8 \ --dns 8.8.4.4 \ --name transmission-openvpn \ haugene/transmission-openvpn && docker run -d \ --link $(docker ps -q --filter "name=transmission-openvpn"):transmission \ -p 8080:8080 \ --name transmission-proxy \ haugene/transmission-openvpn-proxy

Most helpful comment

just a tip..might wan to remove the username/password there ;)

All 5 comments

just a tip..might wan to remove the username/password there ;)

Is there any reason you're running with both LOCAL_NETWORK variable and using a reverse proxy? Are you able to connect to the UI using :9091?

Also... 192.168.1.1/40 is not a valid subnet? Should be /32 at a maximum. If you want to specify the subnet range 192.168.1.1 - 192.168.1.255 it should be 192.168.1.1/24

And, as a last thing. If the transmission container restarts and gets a new IP, the link defined in the proxy will be obsolete. So it needs to be restarted after the transmission container every time in that case. If you can't make the LOCAL_NETWORK stuff work without the proxy I'll give you some commands to use the new service discovery feature from Docker 1.12. Better than --link

Thanks, removing the LOCAL_NETWORK variable solved my problem, and your response made me facepalm myself pretty hard. No issues with your repo, just me!

P.S.
hunter2

Glad to hear it! Haha, hunter2. I knew it felt familiar, just didn't know why. A good start to my day revisiting the escapades of fearless h4xx0r AzureDiamond ;)

aha..learned something new :P

Was this page helpful?
0 / 5 - 0 ratings

Related issues

PriamX picture PriamX  路  3Comments

garret picture garret  路  3Comments

coulterj picture coulterj  路  4Comments

silentArtifact picture silentArtifact  路  3Comments

SuperJakish picture SuperJakish  路  4Comments