mirror of
https://github.com/haugene/docker-transmission-openvpn.git
synced 2025-08-07 06:47:12 +02:00
* DEBUG: print all lines before execution if var DEBUG is set to anything other than false, each bash script will be run with a set -x. This would ease debugging * DEBUG: centralize commands in utils.sh
16 lines
486 B
Bash
Executable File
16 lines
486 B
Bash
Executable File
#!/bin/bash
|
|
#tunnel is down, restore resolv.conf to previous version
|
|
# Source our persisted env variables from container startup
|
|
. /etc/transmission/environment-variables.sh
|
|
source /etc/openvpn/utils.sh
|
|
|
|
if ls /etc/resolv.conf-*.sv 1> /dev/null 2>&1; then
|
|
cp /etc/resolv.conf-*.sv /etc/resolv.conf
|
|
echo "resolv.conf was restored"
|
|
else
|
|
echo "resolv.conf backup not found, could not restore"
|
|
fi
|
|
|
|
/etc/transmission/stop.sh
|
|
[[ -f /opt/privoxy/stop.sh ]] && /opt/privoxy/stop.sh
|