mirror of
https://github.com/haugene/docker-transmission-openvpn.git
synced 2025-08-07 14:57:20 +02:00
Docs review (#2507)
* Fix spelling mistakes * Fix some minor typos * Improve grammar / readability
This commit is contained in:
parent
e554f9536b
commit
2eff0d0143
@ -5,7 +5,7 @@
|
|||||||
|
|
||||||
This container contains OpenVPN and Transmission with a configuration
|
This container contains OpenVPN and Transmission with a configuration
|
||||||
where Transmission is running only when OpenVPN has an active tunnel.
|
where Transmission is running only when OpenVPN has an active tunnel.
|
||||||
It has built in support for many popular VPN providers to make the setup easier.
|
It has built-in support for many popular VPN providers to make the setup easier.
|
||||||
|
|
||||||
## Read this first
|
## Read this first
|
||||||
|
|
||||||
@ -18,12 +18,12 @@ in the [discussions](https://github.com/haugene/docker-transmission-openvpn/disc
|
|||||||
as we're trying to use that for general questions.
|
as we're trying to use that for general questions.
|
||||||
|
|
||||||
If you have found what you believe to be an issue or bug, create an issue and provide
|
If you have found what you believe to be an issue or bug, create an issue and provide
|
||||||
enough details for us to have a chance to reproduce it or undertand what's going on.
|
enough details for us to have a chance to reproduce it or understand what's going on.
|
||||||
**NB:** Be sure to search for similar issues (open and closed) before opening a new one.
|
**NB:** Be sure to search for similar issues (open and closed) before opening a new one.
|
||||||
|
|
||||||
## Quick Start
|
## Quick Start
|
||||||
|
|
||||||
These examples shows valid setups using PIA as provider for both
|
These examples show valid setups using PIA as the provider for both
|
||||||
docker run and docker-compose. Note that you should read some documentation
|
docker run and docker-compose. Note that you should read some documentation
|
||||||
at some point, but this is a good place to start.
|
at some point, but this is a good place to start.
|
||||||
|
|
||||||
@ -92,7 +92,7 @@ and you should expect there to be occasional breakage or even the deletion of th
|
|||||||
## Please help out (about:maintenance)
|
## Please help out (about:maintenance)
|
||||||
This image was created for my own use, but sharing is caring, so it had to be open source.
|
This image was created for my own use, but sharing is caring, so it had to be open source.
|
||||||
It has now gotten quite popular, and that's great! But keeping it up to date, providing support, fixes
|
It has now gotten quite popular, and that's great! But keeping it up to date, providing support, fixes
|
||||||
and new features takes time. If you feel that you're getting a good tool and want to support it, there are a couple of options:
|
and new features take time. If you feel that you're getting a good tool and want to support it, there are a couple of options:
|
||||||
|
|
||||||
A small montly amount through [](https://www.patreon.com/haugene) or
|
A small montly amount through [](https://www.patreon.com/haugene) or
|
||||||
a one time donation with [](https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=73XHRSK65KQYC)
|
a one time donation with [](https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=73XHRSK65KQYC)
|
||||||
|
@ -1,10 +1,10 @@
|
|||||||
# The basic building blocks
|
# The basic building blocks
|
||||||
|
|
||||||
## The goal
|
## The goal
|
||||||
|
|
||||||
The core functionality of this image is to let the user run a
|
The core functionality of this image is to let the user run a
|
||||||
VPN tunnel and Transmission as easy as possible. Transmission
|
VPN tunnel and Transmission as easy as possible. Transmission
|
||||||
should only run while the VPN is active and any disconnect
|
should only run while the VPN is active, and any disconnect
|
||||||
from VPN should cause Transmission to stop.
|
from VPN should cause Transmission to stop.
|
||||||
|
|
||||||
The container should provide community best practices on how to configure the kill switch, firewall and tweaks on the
|
The container should provide community best practices on how to configure the kill switch, firewall and tweaks on the
|
||||||
@ -25,12 +25,12 @@ This script is responsible for doing initial setup and preparing what is needed
|
|||||||
|
|
||||||
## Starting OpenVPN
|
## Starting OpenVPN
|
||||||
|
|
||||||
The main purpose of the startup script is to figure out which OpenVPN config to use.
|
The main purpose of the start-up script is to figure out which OpenVPN config to use.
|
||||||
OpenVPN itself can be started with a single argument, and that is the config file.
|
OpenVPN itself can be started with a single argument, and that is the config file.
|
||||||
We also add a few more to tell it to start Transmission when the VPN tunnel is
|
We also add a few more to tell it to start Transmission when the VPN tunnel is
|
||||||
started and to stop Transmission when OpenVPN is stopped. That's it.
|
started and to stop Transmission when OpenVPN is stopped. That's it.
|
||||||
|
|
||||||
Apart from that, the script does some firewall config, vpn interface setup and possibly other
|
Apart from that, the script does some firewall config, VPN interface setup and possibly other
|
||||||
things based on your settings. There are also some reserved script names that a user can mount/add to
|
things based on your settings. There are also some reserved script names that a user can mount/add to
|
||||||
the container to include their own scripts as a part of the setup or teardown of the container.
|
the container to include their own scripts as a part of the setup or teardown of the container.
|
||||||
|
|
||||||
@ -38,19 +38,19 @@ Anyways! You have probably seen the docker run and docker-compose configuration
|
|||||||
and you've put two and two together: This is where environment variables come in.
|
and you've put two and two together: This is where environment variables come in.
|
||||||
Setting environment variables is a common way to pass configuration options to containers
|
Setting environment variables is a common way to pass configuration options to containers
|
||||||
and it is the way we have chosen to do it here.
|
and it is the way we have chosen to do it here.
|
||||||
So far we've explained the need for `OPENVPN_PROVIDER` and `OPENVPN_CONFIG`. We use the
|
So far, we've explained the need for `OPENVPN_PROVIDER` and `OPENVPN_CONFIG`. We use the
|
||||||
combination of these two to find the right config. `OPENVPN_CONFIG` is not set as a mandatory
|
combination of these two to find the right config. `OPENVPN_CONFIG` is not set as a mandatory
|
||||||
option as each provider should have a default config that will be used if none is set.
|
option as each provider should have a default config that will be used if none is set.
|
||||||
|
|
||||||
With the config file identified we're ready to start OpenVPN, the only thing missing are probably
|
With the config file identified we're ready to start OpenVPN, the only thing missing are probably
|
||||||
a username and password. There are some free providers out there, but they are the exceptions to the rule.
|
a username and password. There are some free providers out there, but they are the exceptions to the rule.
|
||||||
We have to inject the username/password into the config somehow. Again there are exceptions but the majority
|
We must inject the username/password into the config somehow. Again there are exceptions but the majority
|
||||||
of configs from regular providers contain a line with `auth-user-pass` which will make OpenVPN prompt for username
|
of configs from regular providers contain a line with `auth-user-pass` which will make OpenVPN prompt for username
|
||||||
and password when you start a connection. That will obviously not work for us so we need to modify that option.
|
and password when you start a connection. That will obviously not work for us, so we need to modify that option.
|
||||||
If it's followed by a path to a file, it will read the first line of that file as username and the second line as password.
|
If it's followed by a path to a file, it will read the first line of that file as username and the second line as password.
|
||||||
|
|
||||||
You provide your username and password as `OPENVPN_USERNAME` and `OPENVPN_PASSWORD`. These will be
|
You provide your username and password as `OPENVPN_USERNAME` and `OPENVPN_PASSWORD`. These will be
|
||||||
written into two lines in a file called `/config/openvpn-credentials.txt` on startup by the start script.
|
written into two lines in a file called `/config/openvpn-credentials.txt` on start-up by the start script.
|
||||||
Having written your username/password to a file, we can successfully start OpenVPN.
|
Having written your username/password to a file, we can successfully start OpenVPN.
|
||||||
|
|
||||||
## Starting Transmission
|
## Starting Transmission
|
||||||
@ -69,7 +69,7 @@ The up script will be called with a number of parameters from OpenVPN, and among
|
|||||||
This IP is the one we've been assigned by DHCP from the OpenVPN server we're connecting to.
|
This IP is the one we've been assigned by DHCP from the OpenVPN server we're connecting to.
|
||||||
We use this value to override Transmission’s bind address, so we'll only listen for traffic from peers on the VPN interface.
|
We use this value to override Transmission’s bind address, so we'll only listen for traffic from peers on the VPN interface.
|
||||||
|
|
||||||
The startup script checks to see if one of the [alternative web UIs](config-options.md#alternative_web_uis) should be used for Transmission.
|
The start-up script checks to see if one of the [alternative web UIs](config-options.md#alternative_web_uis) should be used for Transmission.
|
||||||
It also sets up the user that Transmission should be run as, based on the PUID and PGID passed by the user
|
It also sets up the user that Transmission should be run as, based on the PUID and PGID passed by the user
|
||||||
along with selecting preferred logging output and a few other tweaks.
|
along with selecting preferred logging output and a few other tweaks.
|
||||||
|
|
||||||
@ -87,11 +87,11 @@ the selected properties in settings.json and we're ready to start Transmission i
|
|||||||
|
|
||||||
After starting Transmission there is an optional step that some providers have;
|
After starting Transmission there is an optional step that some providers have;
|
||||||
to get an open port and set it in Transmission. **Opening a port in your local router does not work**.
|
to get an open port and set it in Transmission. **Opening a port in your local router does not work**.
|
||||||
I made that bold because it's a recurring theme. It's not intuitive until it is I guess.
|
I made that bold because it's a recurring theme. It's not intuitive until it is, I guess.
|
||||||
Since all your traffic is going through the VPN, which is kind of the point, the port you have to open is not on your router.
|
Since all your traffic is going through the VPN, which is kind of the point, the port you have to open is not on your router.
|
||||||
Your router's external IP address is the destination of those packets. It is on your VPN provider’s end that it has to be opened.
|
Your router's external IP address is the destination of those packets. It is on your VPN provider’s end that it has to be opened.
|
||||||
Some providers support this, others don't. We try to write scripts for those that do and that script will be executed
|
Some providers support this, others don't. We try to write scripts for those that do, and that script will be executed
|
||||||
after starting Transmission if it exists for your provider.
|
after starting Transmission if it exists for your provider.
|
||||||
|
|
||||||
At this point, Transmission is running and everything is great!
|
At this point, Transmission is running, and everything is great!
|
||||||
But you might not be able to access it, and that's the topic of the [networking section](vpn-networking.md).
|
But you might not be able to access it, and that's the topic of the [networking section](vpn-networking.md).
|
||||||
|
@ -4,13 +4,13 @@
|
|||||||
| ------------------ | --------------------------------- | ------------------------------------------------------------------------------------------------------- |
|
| ------------------ | --------------------------------- | ------------------------------------------------------------------------------------------------------- |
|
||||||
| `OPENVPN_PROVIDER` | Sets the OpenVPN provider to use. | `OPENVPN_PROVIDER=provider`. Supported providers and their config values are listed in the table above. |
|
| `OPENVPN_PROVIDER` | Sets the OpenVPN provider to use. | `OPENVPN_PROVIDER=provider`. Supported providers and their config values are listed in the table above. |
|
||||||
| `OPENVPN_USERNAME` | Your OpenVPN username | `OPENVPN_USERNAME=asdf` |
|
| `OPENVPN_USERNAME` | Your OpenVPN username | `OPENVPN_USERNAME=asdf` |
|
||||||
| `OPENVPN_PASSWORD` | Your OpenVPN password, beware of special charcters. Docker run vs docker-compose (using yaml) interprete special characters differently, see [Yaml special characters](https://support.asg.com/mob/mvw/10_0/mv_ag/using_quotes_with_yaml_special_characters.htm) | `OPENVPN_PASSWORD=asdf` |
|
| `OPENVPN_PASSWORD` | Your OpenVPN password, beware of special characters. Docker run vs docker-compose (using YAML) interpret special characters differently, see [Yaml special characters](https://support.asg.com/mob/mvw/10_0/mv_ag/using_quotes_with_yaml_special_characters.htm) | `OPENVPN_PASSWORD=asdf` |
|
||||||
|
|
||||||
Docker secrets are available to define OPENVPN_USER and OPENVPN_PASSWORD.
|
Docker secrets are available to define OPENVPN_USER and OPENVPN_PASSWORD.
|
||||||
|
|
||||||
* remove OPENVPN_USERNAME, OPENVPN_PASSWORD from environment.
|
* remove OPENVPN_USERNAME, OPENVPN_PASSWORD from environment.
|
||||||
* write your credentials in one file: openvpn_creds
|
* write your credentials in one file: openvpn_creds
|
||||||
* add to your compose yaml:
|
* add to your compose YAML:
|
||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
version: '3.8'
|
version: '3.8'
|
||||||
@ -31,7 +31,7 @@ secrets:
|
|||||||
| ------------------- | --------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------- |
|
| ------------------- | --------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------- |
|
||||||
| `OPENVPN_CONFIG` | Sets the OpenVPN endpoint to connect to. | `OPENVPN_CONFIG=UK Southampton` |
|
| `OPENVPN_CONFIG` | Sets the OpenVPN endpoint to connect to. | `OPENVPN_CONFIG=UK Southampton` |
|
||||||
| `OPENVPN_OPTS` | Will be passed to OpenVPN on startup | See [OpenVPN doc](https://openvpn.net/index.php/open-source/documentation/manuals/65-openvpn-20x-manpage.html) |
|
| `OPENVPN_OPTS` | Will be passed to OpenVPN on startup | See [OpenVPN doc](https://openvpn.net/index.php/open-source/documentation/manuals/65-openvpn-20x-manpage.html) |
|
||||||
| `LOCAL_NETWORK` | Sets the local network that should have access. Accepts comma separated list. | `LOCAL_NETWORK=192.168.0.0/24` |
|
| `LOCAL_NETWORK` | Sets the local network that should have access. Accepts comma-separated list. | `LOCAL_NETWORK=192.168.0.0/24` |
|
||||||
| `CREATE_TUN_DEVICE` | Creates /dev/net/tun device inside the container, mitigates the need to mount the device from the host | `CREATE_TUN_DEVICE=true` |
|
| `CREATE_TUN_DEVICE` | Creates /dev/net/tun device inside the container, mitigates the need to mount the device from the host | `CREATE_TUN_DEVICE=true` |
|
||||||
| `PEER_DNS` | Controls whether to use the DNS provided by the OpenVPN endpoint. | To use your host DNS rather than what is provided by OpenVPN, set `PEER_DNS=false`. This allows for potential DNS leakage. |
|
| `PEER_DNS` | Controls whether to use the DNS provided by the OpenVPN endpoint. | To use your host DNS rather than what is provided by OpenVPN, set `PEER_DNS=false`. This allows for potential DNS leakage. |
|
||||||
| `PEER_DNS_PIN_ROUTES` | Controls whether to force traffic to peer DNS through the OpenVPN tunnel. | To disable this default, set `PEER_DNS_PIN_ROUTES=false`. |
|
| `PEER_DNS_PIN_ROUTES` | Controls whether to force traffic to peer DNS through the OpenVPN tunnel. | To disable this default, set `PEER_DNS_PIN_ROUTES=false`. |
|
||||||
@ -54,7 +54,7 @@ If TRANSMISSION_PEER_PORT_RANDOM_ON_START is enabled then it allows traffic to t
|
|||||||
| ----------------------------- | --------------------------------------------------------------------------------------------------------------------------- | ---------------------------------- |
|
| ----------------------------- | --------------------------------------------------------------------------------------------------------------------------- | ---------------------------------- |
|
||||||
| `ENABLE_UFW` | Enables the firewall | `ENABLE_UFW=true` |
|
| `ENABLE_UFW` | Enables the firewall | `ENABLE_UFW=true` |
|
||||||
| `UFW_ALLOW_GW_NET` | Allows the gateway network through the firewall. Off defaults to only allowing the gateway. | `UFW_ALLOW_GW_NET=true` |
|
| `UFW_ALLOW_GW_NET` | Allows the gateway network through the firewall. Off defaults to only allowing the gateway. | `UFW_ALLOW_GW_NET=true` |
|
||||||
| `UFW_EXTRA_PORTS` | Allows the comma separated list of ports through the firewall. Respects UFW_ALLOW_GW_NET. | `UFW_EXTRA_PORTS=9910,23561,443` |
|
| `UFW_EXTRA_PORTS` | Allows the comma-separated list of ports through the firewall. Respects UFW_ALLOW_GW_NET. | `UFW_EXTRA_PORTS=9910,23561,443` |
|
||||||
| `UFW_DISABLE_IPTABLES_REJECT` | Prevents the use of `REJECT` in the `iptables` rules, for hosts without the `ipt_REJECT` module (such as the Synology NAS). | `UFW_DISABLE_IPTABLES_REJECT=true` |
|
| `UFW_DISABLE_IPTABLES_REJECT` | Prevents the use of `REJECT` in the `iptables` rules, for hosts without the `ipt_REJECT` module (such as the Synology NAS). | `UFW_DISABLE_IPTABLES_REJECT=true` |
|
||||||
|
|
||||||
### Health check option
|
### Health check option
|
||||||
@ -102,11 +102,11 @@ You may set the following parameters to customize the user id that runs Transmis
|
|||||||
|
|
||||||
### Transmission configuration options
|
### Transmission configuration options
|
||||||
|
|
||||||
In previous versions of this container the settings were not persistent but was generated from environment variables on container startup.
|
In previous versions of this container the settings were not persistent but were generated from environment variables on container startup.
|
||||||
This had the benefit of being very explicit and reproducable but you had to provide Transmission config as environment variables if you
|
This had the benefit of being very explicit and reproducible but you had to provide Transmission config as environment variables if you
|
||||||
wanted them to stay that way between container restarts. This felt cumbersome to many.
|
wanted them to stay that way between container restarts. This felt cumbersome to many.
|
||||||
|
|
||||||
As of version 4.2 this is no longer true. Settings are now persisted in the `/config/transmission-home` folder in the container and as
|
As of version 4.2, this is no longer true. Settings are now persisted in the `/config/transmission-home` folder in the container and as
|
||||||
long as you mount `/config` you should be able to configure Transmission using the UI as you normally would.
|
long as you mount `/config` you should be able to configure Transmission using the UI as you normally would.
|
||||||
If you are using the container from earlier versions and have not changed the location of transmission-home to /config, you will see a warning message that the default has changed.
|
If you are using the container from earlier versions and have not changed the location of transmission-home to /config, you will see a warning message that the default has changed.
|
||||||
You can manually move the folder to your /config volume directory after stopping the container and adding the /config mount to your container setup (compose/run etc).
|
You can manually move the folder to your /config volume directory after stopping the container and adding the /config mount to your container setup (compose/run etc).
|
||||||
@ -145,27 +145,27 @@ By default, Transmission will log to a file in `TRANSMISSION_HOME/transmission.l
|
|||||||
|
|
||||||
To log to stdout instead set the environment variable `LOG_TO_STDOUT` to `true`.
|
To log to stdout instead set the environment variable `LOG_TO_STDOUT` to `true`.
|
||||||
|
|
||||||
_Note_: By default, stdout is what container engines read logs from. Set this to true to have Tranmission logs in commands like `docker logs` and `kubectl logs`. OpenVPN currently only logs to stdout.
|
_Note_: By default, stdout is what container engines read logs from. Set this to true to have Transmission logs in commands like `docker logs` and `kubectl logs`. OpenVPN currently only logs to stdout.
|
||||||
|
|
||||||
### Custom scripts
|
### Custom scripts
|
||||||
|
|
||||||
If you ever need to run custom code before or after Transmission is executed or stopped, you can use the custom scripts feature.
|
If you ever need to run custom code before or after Transmission is executed or stopped, you can use the custom scripts feature.
|
||||||
Custom scripts are located in the /scripts directory which is empty by default.
|
Custom scripts are located in the `/scripts` directory which is empty by default.
|
||||||
To enable this feature, you'll need to mount the /scripts directory.
|
To enable this feature, you'll need to mount the `/scripts` directory.
|
||||||
|
|
||||||
Once /scripts is mounted you'll need to write your custom code in the following bash shell scripts:
|
Once `/scripts` is mounted you'll need to write your custom code in the following bash shell scripts:
|
||||||
|
|
||||||
| Script | Function |
|
| Script | Function |
|
||||||
| ----------------------------------- | ------------------------------------------------------------ |
|
| ----------------------------------- | ------------------------------------------------------------ |
|
||||||
| /scripts/openvpn-pre-start.sh | This shell script will be executed before openvpn start |
|
| /scripts/openvpn-pre-start.sh | This shell script will be executed before OpenVPN starts |
|
||||||
| /scripts/openvpn-post-config.sh | This shell script will be executed after openvpn config |
|
| /scripts/openvpn-post-config.sh | This shell script will be executed after OpenVPN config |
|
||||||
| /scripts/transmission-pre-start.sh | This shell script will be executed before transmission start |
|
| /scripts/transmission-pre-start.sh | This shell script will be executed before transmission starts |
|
||||||
| /scripts/transmission-post-start.sh | This shell script will be executed after transmission start |
|
| /scripts/transmission-post-start.sh | This shell script will be executed after transmission starts |
|
||||||
| /scripts/routes-post-start.sh | This shell script will be executed after routes are added |
|
| /scripts/routes-post-start.sh | This shell script will be executed after routes are added |
|
||||||
| /scripts/transmission-pre-stop.sh | This shell script will be executed before transmission stop |
|
| /scripts/transmission-pre-stop.sh | This shell script will be executed before transmission stops |
|
||||||
| /scripts/transmission-post-stop.sh | This shell script will be executed after transmission stop |
|
| /scripts/transmission-post-stop.sh | This shell script will be executed after transmission stops |
|
||||||
|
|
||||||
Don't forget to include the #!/bin/bash shebang and to make the scripts executable using chmod a+x
|
Don't forget to include the `#!/bin/bash` shebang and to make the scripts executable using `chmod a+x`
|
||||||
|
|
||||||
### Debugging
|
### Debugging
|
||||||
|
|
||||||
|
@ -24,7 +24,7 @@ any of these commands. If any command breaks with this principle it will be note
|
|||||||
|
|
||||||
For this container to work, you have to have a working Docker installation on your host.
|
For this container to work, you have to have a working Docker installation on your host.
|
||||||
|
|
||||||
We'll begin very simple with this command that will print a welcome message if Docker is properly installed.
|
We'll begin very simply with this command that will print a welcome message if Docker is properly installed.
|
||||||
```
|
```
|
||||||
docker run --rm hello-world
|
docker run --rm hello-world
|
||||||
```
|
```
|
||||||
@ -82,7 +82,7 @@ SIGTERM[soft,auth-failure] received, process exiting
|
|||||||
```
|
```
|
||||||
|
|
||||||
And this is not nothing. The container has made contact with the VPN server and they have agreed
|
And this is not nothing. The container has made contact with the VPN server and they have agreed
|
||||||
that you do not have provided correct authentication. So we're getting somewhere.
|
that you have not provided correct authentication. So we're getting somewhere.
|
||||||
|
|
||||||
## Running with a valid configuration
|
## Running with a valid configuration
|
||||||
|
|
||||||
@ -91,15 +91,15 @@ This is what the container needs to be able to connect to VPN. The config is not
|
|||||||
all providers should have a default that is used if you don't set it. But I will set it here anyways as
|
all providers should have a default that is used if you don't set it. But I will set it here anyways as
|
||||||
I think it's good to know where and what you're connecting to.
|
I think it's good to know where and what you're connecting to.
|
||||||
|
|
||||||
The command is basically the same. I'm going to stick with PIA/france as I am a PIA user, but you should set
|
The command is basically the same. I'm going to stick with PIA/France as I am a PIA user, but you should set
|
||||||
one of the [supported providers](supported-providers.md) or provide your own config using the
|
one of the [supported providers](supported-providers.md) or provide your own config using the
|
||||||
[custom configuration option](supported-providers.md#using_a_custom_provider). Since I'm now expecting to connect
|
[custom configuration option](supported-providers.md#using_a_custom_provider). Since I'm now expecting to connect
|
||||||
successfully to my VPN provider I have to give the container elevated access to modify networking needed to
|
successfully to my VPN provider, I have to give the container elevated access to modify networking needed to
|
||||||
establish a VPN tunnel. I'll add the `--cap-add=NET_ADMIN` and you can read more about
|
establish a VPN tunnel. I'll add the `--cap-add=NET_ADMIN` and you can read more about
|
||||||
that [here](https://docs.docker.com/engine/reference/run/#runtime-privilege-and-linux-capabilities).
|
that [here](https://docs.docker.com/engine/reference/run/#runtime-privilege-and-linux-capabilities).
|
||||||
|
|
||||||
Also because I'm using PIA and they support port forwarding which is automatically configured in this
|
Also because I'm using PIA and they support port forwarding which is automatically configured in this
|
||||||
container I will disable that script for now. It's unnecessary at this point and I don't want to introduce
|
container, I will disable that script for now. It's unnecessary at this point and I don't want to introduce
|
||||||
more error sources than I have to.
|
more error sources than I have to.
|
||||||
|
|
||||||
```
|
```
|
||||||
|
14
docs/faq.md
14
docs/faq.md
@ -8,8 +8,8 @@
|
|||||||
* [Error resolving host address](#error_resolving_host_address)
|
* [Error resolving host address](#error_resolving_host_address)
|
||||||
* [Container loses connection after some time](#container_loses_connection_after_some_time)
|
* [Container loses connection after some time](#container_loses_connection_after_some_time)
|
||||||
* [Set the ping-exit option for OpenVPN and restart-flag in Docker](#set_the_ping-exit_option_for_openvpn_and_restart-flag_in_docker)
|
* [Set the ping-exit option for OpenVPN and restart-flag in Docker](#set_the_ping-exit_option_for_openvpn_and_restart-flag_in_docker)
|
||||||
* [Use a third party tool to monitor and restart the container](#use_a_third_party_tool_to_monitor_and_restart_the_container)
|
* [Use a third-party tool to monitor and restart the container](#use_a_third-party_tool_to_monitor_and_restart_the_container)
|
||||||
* [Send Username Password via file](#send_username_password_via_file)
|
* [Send Username Password via file](#send_username_and_password_via_a_file)
|
||||||
* [AUTH: Received control message: AUTH_FAILED](#auth_received_control_message_auth_failed)
|
* [AUTH: Received control message: AUTH_FAILED](#auth_received_control_message_auth_failed)
|
||||||
|
|
||||||
## The container runs, but I can't access the web UI
|
## The container runs, but I can't access the web UI
|
||||||
@ -79,7 +79,7 @@ but an invalid target route that would cause this error might be
|
|||||||
|
|
||||||
To check your value, you can use a [subnet calculator](https://www.calculator.net/ip-subnet-calculator.html).
|
To check your value, you can use a [subnet calculator](https://www.calculator.net/ip-subnet-calculator.html).
|
||||||
* Enter your IP Address - the portion before the mask, `10.20.30.45` here
|
* Enter your IP Address - the portion before the mask, `10.20.30.45` here
|
||||||
* select the subnet that matches - the `/24` portion here
|
* Select the subnet that matches - the `/24` portion here
|
||||||
* Take the Network Address that is returned - `10.20.30.0` in this case
|
* Take the Network Address that is returned - `10.20.30.0` in this case
|
||||||
|
|
||||||
## TUNSETIFF tun: Operation not permitted
|
## TUNSETIFF tun: Operation not permitted
|
||||||
@ -141,7 +141,7 @@ solve the problem for you if it is your local network that in some way is blocki
|
|||||||
|
|
||||||
## Container loses connection after some time
|
## Container loses connection after some time
|
||||||
|
|
||||||
For some users, on some platforms, apparently, this is an issue. I have not encountered this myself - but there is no doubt that it's recurring.
|
For some users, on some platforms, this is an issue. I have not encountered this myself - but there is no doubt that it's recurring.
|
||||||
Why does the container lose connectivity? That we don't know and it could be many different reasons that manifest the same symptoms.
|
Why does the container lose connectivity? That we don't know and it could be many different reasons that manifest the same symptoms.
|
||||||
We do however have some possible solutions.
|
We do however have some possible solutions.
|
||||||
|
|
||||||
@ -168,13 +168,13 @@ if basic network connectivity is broken. You can write your own script and add i
|
|||||||
|
|
||||||
This container has the `autoheal` label by default so it is compatible with the [willfarrell/autoheal image](https://hub.docker.com/r/willfarrell/autoheal/)
|
This container has the `autoheal` label by default so it is compatible with the [willfarrell/autoheal image](https://hub.docker.com/r/willfarrell/autoheal/)
|
||||||
|
|
||||||
## Send Username Password via file
|
## Send Username and Password via a file
|
||||||
|
|
||||||
Depending on your setup, you may not want to send your VPN user/pass via environment variables (the main reason being, it is accessible via docker inspect). If you prefer, there is a way to configure the container to use a file instead.
|
Depending on your setup, you may not want to send your VPN user/pass via environment variables (the main reason being, it is accessible via docker inspect). If you prefer, there is a way to configure the container to use a file instead.
|
||||||
|
|
||||||
*Procedure*
|
*Procedure*
|
||||||
1. create a text file with username and password in it, each on a separate line: eg:
|
1. Create a text file with a username and password in it, each on a separate line.
|
||||||
For this example we will pretend, it is located at: `./openvpn-credentials.txt`
|
For this example, we will assume it is located at `./openvpn-credentials.txt`
|
||||||
```
|
```
|
||||||
this_is_my_username
|
this_is_my_username
|
||||||
this_is_my_password
|
this_is_my_password
|
||||||
|
@ -7,7 +7,7 @@ $ docker run -d \
|
|||||||
--name "transmission-rss" \
|
--name "transmission-rss" \
|
||||||
haugene/transmission-rss
|
haugene/transmission-rss
|
||||||
```
|
```
|
||||||
At first start a transission-rss.conf file will be created in /etc if no manual one is mounted
|
At first start a transmission-rss.conf file will be created in /etc if no manual one is mounted
|
||||||
A manual transmission-rss.conf file can be mounted into the container to add additional parameters, e.g. login details to rpc
|
A manual transmission-rss.conf file can be mounted into the container to add additional parameters, e.g. login details to rpc
|
||||||
example:
|
example:
|
||||||
```
|
```
|
||||||
@ -35,4 +35,4 @@ login:
|
|||||||
username: <username>
|
username: <username>
|
||||||
password: <password>
|
password: <password>
|
||||||
|
|
||||||
```
|
```
|
||||||
|
@ -1,16 +1,16 @@
|
|||||||
# Running the container
|
# Running the container
|
||||||
|
|
||||||
Many platforms ship with a Docker runtime and have their own way of setting this up.
|
Many platforms ship with a Docker runtime and have their own way of setting this up.
|
||||||
I'm then thinking about NAS servers specifically, but also Unraid and others. In addition to this we have
|
I'm then thinking about NAS servers specifically, but also Unraid and others. In addition to this, we have
|
||||||
the container management solutions like [Portainer](https://www.portainer.io/)
|
container management solutions like [Portainer](https://www.portainer.io/)
|
||||||
|
|
||||||
This page will only discuss the tooling that a Docker installation comes with. That means `docker run ..`
|
This page will only discuss the tooling that a Docker installation comes with. That means `docker run ..`
|
||||||
and `docker-compose`. In the end that is what the other managers do as well and it's the common ground here.
|
and `docker-compose`. In the end, that is what the other managers do as well and it's the common ground here.
|
||||||
I'm very happy to set up a platform specific installation page and link to it from here.
|
I'm very happy to set up a platform-specific installation page and link to it from here.
|
||||||
Open an issue or PR if you want to contribute with documentation for your favourite platform.
|
Open an issue or PR if you want to contribute with documentation for your favourite platform.
|
||||||
|
|
||||||
|
|
||||||
The images available on the Docker Hub are multiarch manifests. This means that they point to multiple images
|
The images available on the Docker Hub are multi-arch manifests. This means that they point to multiple images
|
||||||
that are built for different CPU architectures like ARM for Raspberry Pi. You can `haugene/transmission-openvpn`
|
that are built for different CPU architectures like ARM for Raspberry Pi. You can `haugene/transmission-openvpn`
|
||||||
on any of these architectures and Docker will get the correct one.
|
on any of these architectures and Docker will get the correct one.
|
||||||
|
|
||||||
@ -67,8 +67,8 @@ the same options being sent to the Docker engine as the run statement before it.
|
|||||||
#### 1. The container assumes that you mount a folder to /data
|
#### 1. The container assumes that you mount a folder to /data
|
||||||
|
|
||||||
Technically you don't have to do this, but it is by far the most manageable way of getting
|
Technically you don't have to do this, but it is by far the most manageable way of getting
|
||||||
the downloaded files onto your host system **and** Transmission will store it's state there.
|
the downloaded files onto your host system **and** Transmission will store its state there.
|
||||||
So if you don't mount this directory then you will loose all your torrents on image updates.
|
So if you don't mount this directory then you will lose all your torrents on image updates.
|
||||||
|
|
||||||
#### 2. It is not mandatory, but setting OPENVPN_CONFIG is good
|
#### 2. It is not mandatory, but setting OPENVPN_CONFIG is good
|
||||||
|
|
||||||
@ -78,10 +78,10 @@ I also believe that tinkering with this builds some familiarity with the image a
|
|||||||
|
|
||||||
We're now moving towards a setup where we download the configs for our providers when the container starts.
|
We're now moving towards a setup where we download the configs for our providers when the container starts.
|
||||||
That is great from a maintenance perspective, but it also means that we don't know the valid choices for the providers ahead of time.
|
That is great from a maintenance perspective, but it also means that we don't know the valid choices for the providers ahead of time.
|
||||||
A tip for finding out is to set `OPENVPN_CONFIG=dummy` and start it. This will fail, but in the logs it will print all the valid options.
|
A tip for finding out is to set `OPENVPN_CONFIG=dummy` and start it. This will fail, but in the logs, it will print all the valid options.
|
||||||
|
|
||||||
Pro tip: choose multiple servers. For example: `OPENVPN_CONFIG=france,sweden,austria,italy,belgium`
|
Pro tip: choose multiple servers. For example: `OPENVPN_CONFIG=france,sweden,austria,italy,belgium`
|
||||||
This will ensure a location near you, but at the same time it will allow some redundancy. Set Docker to restart the container
|
This will ensure a location near you, but at the same time, it will allow some redundancy. Set Docker to restart the container
|
||||||
automatically and you have a failover mechanism. The container chooses one of the configs at random when it starts and it will bounce
|
automatically and you have a failover mechanism. The container chooses one of the configs at random when it starts and it will bounce
|
||||||
from server to server until it finds one that works.
|
from server to server until it finds one that works.
|
||||||
|
|
||||||
@ -92,9 +92,9 @@ The `LOCAL_NETWORK=192.168.0.0/16` tries to fix this for you, but it might not w
|
|||||||
If your local network is in the `10.x.y.z` space for example then you need to set `LOCAL_NETWORK=10.x.0.0/16` or `LOCAL_NETWORK=10.x.y.0/24`.
|
If your local network is in the `10.x.y.z` space for example then you need to set `LOCAL_NETWORK=10.x.0.0/16` or `LOCAL_NETWORK=10.x.y.0/24`.
|
||||||
These are called CIDR addresses and you can read up on them. The short story is that /24 will allow for any value in the last digit place
|
These are called CIDR addresses and you can read up on them. The short story is that /24 will allow for any value in the last digit place
|
||||||
while /16 will allow any value in the two last places. Be sure to only allow IPs that are in the [private IP ranges](https://en.wikipedia.org/wiki/Private_network).
|
while /16 will allow any value in the two last places. Be sure to only allow IPs that are in the [private IP ranges](https://en.wikipedia.org/wiki/Private_network).
|
||||||
This option punches a hole in the VPN for the IPs that you specify. It is neccessary to reach your Web UI but narrower ranges are better than wide ones.
|
This option punches a hole in the VPN for the IPs that you specify. It is necessary to reach your Web UI but narrower ranges are better than wide ones.
|
||||||
|
|
||||||
With that said. If you know that you're on a "typical" network with your router at 192.168.1.1, then `LOCAL_NETWORK=192.168.1.0/24` is better than `LOCAL_NETWORK=192.168.0.0/16`. That way you only allow access from 192.168.1.x instead of 192.168.x.y.
|
With that said. If you know that you're on a "typical" network with your router at 192.168.1.1, then `LOCAL_NETWORK=192.168.1.0/24` is better than `LOCAL_NETWORK=192.168.0.0/16`. That way you only allow access from 192.168.1.x instead of 192.168.x.y.
|
||||||
|
|
||||||
There is an alternative to the LOCAL_NETWORK environment variable, and that is a reverse proxy in the same docker network as the vpn container.
|
There is an alternative to the LOCAL_NETWORK environment variable, and that is a reverse proxy in the same docker network as the VPN container.
|
||||||
Because this topic is both quite complex and very important there is a separate page on [VPN and Networking](vpn-networking.md) in the container and it goes into depth on why this is.
|
Because this topic is both quite complex and very important there is a separate page on [VPN and Networking](vpn-networking.md) in the container and it goes into depth on why this is.
|
||||||
|
@ -4,22 +4,22 @@ The container used to come bundled with a bunch of config files for a range of V
|
|||||||
This was fine when it was a handful or even a dozen supported providers, but as we approached
|
This was fine when it was a handful or even a dozen supported providers, but as we approached
|
||||||
50 providers and 10k configs there wasn't time for anything else than keeping them up to date.
|
50 providers and 10k configs there wasn't time for anything else than keeping them up to date.
|
||||||
|
|
||||||
So we've tried to come up with a setup that is more maintainable.
|
So we've tried to come up with a more maintainable setup.
|
||||||
We have split the .ovpn configs out to a separate repository at:
|
We have split the .ovpn configs out to a separate repository at:
|
||||||
[https://github.com/haugene/vpn-configs-contrib](https://github.com/haugene/vpn-configs-contrib).
|
[https://github.com/haugene/vpn-configs-contrib](https://github.com/haugene/vpn-configs-contrib).
|
||||||
|
|
||||||
All static configs that has to be manually updated will live there and be pulled on container startup.
|
All static configs that have to be manually updated will live there and be pulled on container startup.
|
||||||
We will try to set up a CODEOWNERS scheme and ask for more help from the community to keep them up to date.
|
We will try to set up a CODEOWNERS scheme and ask for more help from the community to keep them up to date.
|
||||||
|
|
||||||
Some providers are still provided from the core project and those are the one that have implemented
|
Some providers are still provided from the core project and those are the ones that have implemented
|
||||||
a script for fetching the configs dynamically. Going forward we will allow code in this project, not config.
|
a script for fetching the configs dynamically. Going forward we will allow code in this project, not config.
|
||||||
|
|
||||||
So that is the story of how we now have two types of providers: `internal` and `external`.
|
So that is the story of how we now have two types of providers: `internal` and `external`.
|
||||||
The benefit of making a very native support for external configs is that it is much simpler for a user to
|
The benefit of having native support for external configs is that it is much simpler for a user to
|
||||||
make a fork of the config repo and simply tell the container to use his or her fork. This way we can hopefully
|
make a fork of the config repo and simply tell the container to use his or her fork. This way we can hopefully
|
||||||
empower many more to help out with keeping our providers up to date and add new ones.
|
empower many more to help out with keeping our providers up to date and adding new ones.
|
||||||
|
|
||||||
## Out of the box supported providers
|
## Out-of-the-box supported providers
|
||||||
|
|
||||||
If you can't find your provider you are welcome to head over to the
|
If you can't find your provider you are welcome to head over to the
|
||||||
[config repo](https://github.com/haugene/vpn-configs-contrib) to request it or add it yourself.
|
[config repo](https://github.com/haugene/vpn-configs-contrib) to request it or add it yourself.
|
||||||
@ -30,7 +30,7 @@ For more info on that see the [using a custom provider](#using_a_custom_provider
|
|||||||
|
|
||||||
### Internal Providers
|
### Internal Providers
|
||||||
|
|
||||||
These providers are implemented as script in this project and will automatically
|
These providers are implemented as a script in this project and will automatically
|
||||||
download new configs directly from the provider on container startup.
|
download new configs directly from the provider on container startup.
|
||||||
|
|
||||||
| Provider Name | Config Value (`OPENVPN_PROVIDER`) |
|
| Provider Name | Config Value (`OPENVPN_PROVIDER`) |
|
||||||
@ -46,7 +46,7 @@ These providers are fetched from our [config repo](https://github.com/haugene/vp
|
|||||||
They have to be manually updated in that repo when the provider changes them but we're trying to keep them up to date.
|
They have to be manually updated in that repo when the provider changes them but we're trying to keep them up to date.
|
||||||
|
|
||||||
Note that we try to keep this list in sync but it is the files and folders in the config repo that ultimately
|
Note that we try to keep this list in sync but it is the files and folders in the config repo that ultimately
|
||||||
is the most up to date list of configs and providers that are supported.
|
is the most up-to-date list of configs and providers that are supported.
|
||||||
|
|
||||||
|
|
||||||
| Provider Name | Config Value (`OPENVPN_PROVIDER`) |
|
| Provider Name | Config Value (`OPENVPN_PROVIDER`) |
|
||||||
@ -102,13 +102,13 @@ is the most up to date list of configs and providers that are supported.
|
|||||||
## Use your own config without building the image
|
## Use your own config without building the image
|
||||||
|
|
||||||
If you have a .ovpn file from your VPN provider and you want to use it but you either don't
|
If you have a .ovpn file from your VPN provider and you want to use it but you either don't
|
||||||
know how to build the image yourself or you don't want to there is another way.
|
know how to build the image yourself or if you don't want to there is another way.
|
||||||
|
|
||||||
Check out the [guide for this](https://github.com/haugene/vpn-configs-contrib/blob/main/CONTRIBUTING.md)
|
Check out the [guide for this](https://github.com/haugene/vpn-configs-contrib/blob/main/CONTRIBUTING.md)
|
||||||
in the config repo.
|
in the config repo.
|
||||||
|
|
||||||
## Using a local single .ovpn file from provider
|
## Using a local single .ovpn file from a provider
|
||||||
For some providers, like AirVPN, the .ovpn files are generated per user and contains credentials.
|
For some providers, like AirVPN, the .ovpn files are generated per user and contain credentials.
|
||||||
These files can not be hosted anywhere publicly visible. Then you can mount the files into the container
|
These files can not be hosted anywhere publicly visible. Then you can mount the files into the container
|
||||||
and use them directly from your local host.
|
and use them directly from your local host.
|
||||||
|
|
||||||
@ -133,7 +133,7 @@ Compose sample:
|
|||||||
### If you only need to mount one file
|
### If you only need to mount one file
|
||||||
|
|
||||||
You might not need to mount a folder of configs. You may just have one config file you want to use.
|
You might not need to mount a folder of configs. You may just have one config file you want to use.
|
||||||
In that case you can just mount it directly. Mounting it as `default.ovpn` will let you omit `OPENVPN_CONFIG` as well.
|
In that case, you can just mount it directly. Mounting it as `default.ovpn` will let you omit `OPENVPN_CONFIG` as well.
|
||||||
|
|
||||||
Compose sample:
|
Compose sample:
|
||||||
```
|
```
|
||||||
|
@ -4,14 +4,14 @@ This causes trouble because OpenVPN will not be able to resolve the host to conn
|
|||||||
If you have this problem use Docker's --dns flag and try using Google's DNS servers by
|
If you have this problem use Docker's --dns flag and try using Google's DNS servers by
|
||||||
adding --dns 8.8.8.8 --dns 8.8.4.4 as parameters to the usual run command.
|
adding --dns 8.8.8.8 --dns 8.8.4.4 as parameters to the usual run command.
|
||||||
|
|
||||||
#### Restart container if connection is lost
|
#### Restart the container if the connection is lost
|
||||||
If the VPN connection fails or the container for any other reason loses connectivity, you want it to recover from it. One way of doing this is to set environment variable `OPENVPN_OPTS=--inactive 3600 --ping 10 --ping-exit 60` and use the --restart=always flag when starting the container. This way OpenVPN will exit if ping fails over a period of time which will stop the container and then the Docker deamon will restart it.
|
If the VPN connection fails or the container for any other reason loses connectivity, you want it to recover from it. One way of doing this is to set the environment variable `OPENVPN_OPTS=--inactive 3600 --ping 10 --ping-exit 60` and use the --restart=always flag when starting the container. This way OpenVPN will exit if ping fails over a period of time which will stop the container and then the Docker daemon will restart it.
|
||||||
|
|
||||||
#### Let other containers use VPN
|
#### Let other containers use the VPN
|
||||||
|
|
||||||
To let other containers use VPN you have to add them to the same Service network as your VPN container runs, you can do this by adding `network_mode: "service:transmission-openvpn"`. Additionally you have to set `depends_on` to the `transmission-openvpn` service to let docker-compose know that your new container should start **after** `transmission-openvpn` is up and running. As final step you can add `healthcheck` to you service.
|
To let other containers use VPN you have to add them to the same Service network as your VPN container runs, you can do this by adding `network_mode: "service:transmission-openvpn"`. Additionally, you have to set `depends_on` to the `transmission-openvpn` service to let docker-compose know that your new container should start **after** `transmission-openvpn` is up and running. As the final step, you can add `healthcheck` to your service.
|
||||||
|
|
||||||
As an example, lets add [Jackett](https://github.com/linuxserver/docker-jackett) to the `transmission-openvpn` network based on example from [Running the container](run-container.md):
|
As an example, let's add [Jackett](https://github.com/linuxserver/docker-jackett) to the `transmission-openvpn` network based on the example from [Running the container](run-container.md):
|
||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
version: '3.3'
|
version: '3.3'
|
||||||
@ -56,17 +56,17 @@ services:
|
|||||||
- transmission-openvpn # Set dependency on transmission-openvpn Container
|
- transmission-openvpn # Set dependency on transmission-openvpn Container
|
||||||
healthcheck: # Here you will check if transmission is reachable from the Jackett container via localhost
|
healthcheck: # Here you will check if transmission is reachable from the Jackett container via localhost
|
||||||
test: curl -f http://localhost:9091 || exit 1
|
test: curl -f http://localhost:9091 || exit 1
|
||||||
# Use this test if you protect your transmission with user and password
|
# Use this test if you protect your transmission with a username and password
|
||||||
# comment test above and un-comment line below.
|
# comment the test above and un-comment the line below.
|
||||||
#test: curl -f http://${TRANSMISSION_RPC_USERNAME}:${TRANSMISSION_RPC_PASSWORD}@localhost:9091 || exit 1
|
#test: curl -f http://${TRANSMISSION_RPC_USERNAME}:${TRANSMISSION_RPC_PASSWORD}@localhost:9091 || exit 1
|
||||||
interval: 5m00s
|
interval: 5m00s
|
||||||
timeout: 10s
|
timeout: 10s
|
||||||
retries: 2
|
retries: 2
|
||||||
```
|
```
|
||||||
|
|
||||||
##### Check if container is using VPN
|
##### Check if the container is using VPN
|
||||||
|
|
||||||
After container starts, simply call `curl` under it to check your IP Address. E.g. for example with Jackett you should see your VPN IP address as output:
|
After the container starts, simply call `curl` under it to check your IP address, for example with Jackett you should see your VPN IP address as output:
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
docker exec jackett curl -s https://api.ipify.org
|
docker exec jackett curl -s https://api.ipify.org
|
||||||
@ -82,14 +82,14 @@ Server: Kestrel
|
|||||||
Location: /UI/Dashboard
|
Location: /UI/Dashboard
|
||||||
```
|
```
|
||||||
|
|
||||||
#### Reach sleep or hybernation on your host if no torrents are active
|
#### Reach sleep or hibernation on your host if no torrents are active
|
||||||
By default Transmission will always [scrape](https://en.wikipedia.org/wiki/Tracker_scrape) trackers, even if all torrents have completed their activities, or they have been paused manually. This will cause Transmission to be always active, therefore never allow your host server to be inactive and go to sleep/hybernation/whatever. If this is something you want, you can add the following variable when creating the container. It will turn off a hidden setting in Tranmsission which will stop the application to scrape trackers for paused torrents. Transmission will become inactive, and your host will reach the desidered state.
|
By default, Transmission will always [scrape](https://en.wikipedia.org/wiki/Tracker_scrape) trackers, even if all torrents have completed their activities, or they have been paused manually. This will cause Transmission to be always active, therefore never allow your host server to be inactive and go to sleep/hibernation/whatever. If this is something you want, you can add the following variable when creating the container. It will turn off a hidden setting in Transmission which will stop the application to scrape trackers for paused torrents. Transmission will become inactive, and your host will reach the desired state.
|
||||||
```bash
|
```bash
|
||||||
-e "TRANSMISSION_SCRAPE_PAUSED_TORRENTS_ENABLED=false"
|
-e "TRANSMISSION_SCRAPE_PAUSED_TORRENTS_ENABLED=false"
|
||||||
```
|
```
|
||||||
|
|
||||||
#### Running it on a NAS
|
#### Running it on a NAS
|
||||||
Several popular NAS platforms supports Docker containers. You should be able to set up
|
Several popular NAS platforms support Docker containers. You should be able to set up
|
||||||
and configure this container using their web interfaces. As of version 3.0 of this image
|
and configure this container using their web interfaces. As of version 3.0 of this image
|
||||||
creates a TUN interface inside the container by default. This previously had to be mounted
|
creates a TUN interface inside the container by default. This previously had to be mounted
|
||||||
from the host which was an issue for some NAS servers. The assumption is that this should
|
from the host which was an issue for some NAS servers. The assumption is that this should
|
||||||
@ -97,17 +97,17 @@ now be fixed. If you have issues and the logs seem to blame "/dev/net/tun" in so
|
|||||||
then you might consider trying to mount a host device and see if that works better.
|
then you might consider trying to mount a host device and see if that works better.
|
||||||
Setting up a TUN device is probably easiest to accomplish by installing an OpenVPN package
|
Setting up a TUN device is probably easiest to accomplish by installing an OpenVPN package
|
||||||
for the NAS. This should set up the device and you can mount it.
|
for the NAS. This should set up the device and you can mount it.
|
||||||
There are some issues involved running it on Synology NAS,
|
There are some issues involved in running it on Synology NAS,
|
||||||
Please see following issue that discusses [solutions](https://github.com/haugene/docker-transmission-openvpn/issues/1542#issuecomment-793605649)
|
Please see this issue that discusses [solutions](https://github.com/haugene/docker-transmission-openvpn/issues/1542#issuecomment-793605649)
|
||||||
|
|
||||||
#### Systemd Integration
|
#### Systemd Integration
|
||||||
On many modern linux systems, including Ubuntu, systemd can be used to start the transmission-openvpn at boot time, and restart it after any failure.
|
On many modern Linux systems, including Ubuntu, systemd can be used to start the transmission-openvpn at boot time, and restart it after any failure.
|
||||||
|
|
||||||
Save the following as `/etc/systemd/system/transmission-openvpn.service`, and replace the OpenVPN PROVIDER/USERNAME/PASSWORD directives with your settings, and add any other directives that you're using.
|
Save the following as `/etc/systemd/system/transmission-openvpn.service`, and replace the OpenVPN PROVIDER/USERNAME/PASSWORD directives with your settings, and add any other directives that you're using.
|
||||||
|
|
||||||
This service is assuming that there is a `bittorrent` user set up with a home directory at `/home/bittorrent/`. The data directory will be mounted at `/home/bittorrent/data/`. This can be changed to whichever user and location you're using.
|
This service is assuming that there is a `bittorrent` user set up with a home directory at `/home/bittorrent/`. The data directory will be mounted at `/home/bittorrent/data/`. This can be changed to whichever user and location you're using.
|
||||||
|
|
||||||
OpenVPN is set to exit if there is a connection failure. OpenVPN exiting triggers the container to also exit, then the `Restart=always` definition in the `transmission-openvpn.service` file tells systems to restart things again.
|
OpenVPN is set to exit if there is a connection failure. OpenVPN exiting triggers the container to also exit, and then the `Restart=always` definition in the `transmission-openvpn.service` file tells systems to restart things again.
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
[Unit]
|
[Unit]
|
||||||
|
12
docs/v3.md
12
docs/v3.md
@ -1,7 +1,7 @@
|
|||||||
|
|
||||||
# Version 3.0 released - we have some breaking changes (but not much)
|
# Version 3.0 released - we have some breaking changes (but not much)
|
||||||
|
|
||||||
Those of you who are following this project knows that we have had some larger changes coming for a while.
|
Those of you who are following this project know that we have had some larger changes coming for a while.
|
||||||
Hobby projects often get last in line for some love and care, and it took longer than I hoped but here we are.
|
Hobby projects often get last in line for some love and care, and it took longer than I hoped but here we are.
|
||||||
|
|
||||||
Some highlights on version 3.0:
|
Some highlights on version 3.0:
|
||||||
@ -9,15 +9,15 @@ Some highlights on version 3.0:
|
|||||||
* We're dropping the ubuntu based image and making alpine the default (reduce double maintenance)
|
* We're dropping the ubuntu based image and making alpine the default (reduce double maintenance)
|
||||||
* We're making Transmission settings persistent by default, removing the need for all the environment variables (but keeping support for it)
|
* We're making Transmission settings persistent by default, removing the need for all the environment variables (but keeping support for it)
|
||||||
* We're making it easier to provide your own OpenVPN (.ovpn) config file - adding scripts in the container to modify provider configs as needed to fit the container setup. (still in early stages at this point)
|
* We're making it easier to provide your own OpenVPN (.ovpn) config file - adding scripts in the container to modify provider configs as needed to fit the container setup. (still in early stages at this point)
|
||||||
* We're adding a standardized way to add scripts for doing necessary setup of a provider. This usually means to download a .ovpn config bundle, unpack it and modify it correctly to work in this container.
|
* We're adding a standardized way to add scripts for doing the necessary setup of a provider. This usually means downloading a .ovpn config bundle, unpacking it and modifying it correctly to work in this container.
|
||||||
|
|
||||||
Hopefully these changes will improve the usability of this container. As maintainers we also hope that it will free up time to keep the container up to date and stable instead of managing thousands of .ovpn files coming and going.
|
Hopefully, these changes will improve the usability of this container. As maintainers, we also hope that it will free up time to keep the container up-to-date and stable instead of managing thousands of .ovpn files coming and going.
|
||||||
|
|
||||||
I'll try to keep a list of breaking changes here, and add to it if we come across more:
|
I'll try to keep a list of breaking changes here, and add to it if we come across more:
|
||||||
|
|
||||||
* The CREATE_TUN_DEVICE variable now defaults to true. Mounting /dev/net/tun will lead to an error message in the logs unless you explicitly set it to false.
|
* The CREATE_TUN_DEVICE variable now defaults to true. Mounting /dev/net/tun will lead to an error message in the logs unless you explicitly set it to false.
|
||||||
* The DOCKER_LOG variable is renamed to LOG_TO_STDOUT
|
* The DOCKER_LOG variable is renamed to LOG_TO_STDOUT
|
||||||
* If Transmission is running but you can't connect to torrents, try deleting (or rename to .backup) the settings.json file and restart.
|
* If Transmission is running but you can't connect to torrents, try deleting the settings.json file (or renaming it to .backup) and restarting.
|
||||||
|
|
||||||
PS: Now more than ever. We appreciate that you report bugs and issues when you find them. But as there might be more than ususal, please make sure you search and look for a similar one before possibly creating a duplicate.
|
PS: Now more than ever. We appreciate that you report bugs and issues when you find them. But as there might be more than usual, please make sure you search and look for a similar one before possibly creating a duplicate.
|
||||||
And you can always revert back to the latest tag on the 2.x versions which is 2.14. Instead of running with `haugene/transmission-openvpn` simply use `haugene/transmission-openvpn:2.14` instead. We hope that won't be necessary though :)
|
And you can always revert to the latest tag on the 2.x versions which is 2.14. Instead of running with `haugene/transmission-openvpn` simply use `haugene/transmission-openvpn:2.14` instead. We hope that won't be necessary though :)
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
### Web proxy configuration options
|
### Web proxy configuration options
|
||||||
|
|
||||||
This container also contains a web-proxy server to allow you to tunnel your web-browser traffic through the same OpenVPN tunnel.
|
This container also contains a web-proxy server to allow you to tunnel your web browser traffic through the same OpenVPN tunnel.
|
||||||
The proxy used is [Privoxy](https://www.privoxy.org/) and is highly configurable using the built in web interface avaialble on [config.privoxy.org](http://config.privoxy.org) (available once your browser is correctly configured to use the localhost:8118 HTTP Proxy).
|
The proxy used is [Privoxy](https://www.privoxy.org/) and is highly configurable using the built-in web interface available on [config.privoxy.org](http://config.privoxy.org) (available once your browser is correctly configured to use the localhost:8118 HTTP Proxy).
|
||||||
This is useful if you are using a private tracker that needs to see you login from the same IP address you are torrenting from.
|
This is useful if you are using a private tracker that needs to see you log in from the same IP address you are torrenting from.
|
||||||
The default listening port is 8118. Note that only ports above 1024 can be specified as all ports below 1024 are privileged
|
The default listening port is 8118. Note that only ports above 1024 can be specified as all ports below 1024 are privileged
|
||||||
and would otherwise require root permissions to run.
|
and would otherwise require root permissions to run.
|
||||||
Remember to add a port binding for your selected (or default) port when starting the container.
|
Remember to add a port binding for your selected (or default) port when starting the container.
|
||||||
@ -12,6 +12,6 @@ Remember to add a port binding for your selected (or default) port when starting
|
|||||||
| `WEBPROXY_ENABLED` | Enables the web proxy | `WEBPROXY_ENABLED=true` |
|
| `WEBPROXY_ENABLED` | Enables the web proxy | `WEBPROXY_ENABLED=true` |
|
||||||
| `WEBPROXY_PORT` | Sets the listening port | `WEBPROXY_PORT=8118` |
|
| `WEBPROXY_PORT` | Sets the listening port | `WEBPROXY_PORT=8118` |
|
||||||
|
|
||||||
The listening address is the one found binded to the eth0 interface.
|
The listening address is the one found bound to the eth0 interface.
|
||||||
|
|
||||||
`adr=$(ip -4 a show eth0| grep -oP "(?<=inet )([^/]+)")`
|
`adr=$(ip -4 a show eth0| grep -oP "(?<=inet )([^/]+)")`
|
||||||
|
Loading…
Reference in New Issue
Block a user