-
Notifications
You must be signed in to change notification settings - Fork 3
/
qbittorrentvpn.tf
66 lines (56 loc) · 1.58 KB
/
qbittorrentvpn.tf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
resource "docker_image" "qbittorrentvpn" {
name = "binhex/arch-qbittorrentvpn:latest"
keep_locally = true
}
resource "docker_container" "qbittorrentvpn" {
name = "qbittorrentvpn"
image = docker_image.qbittorrentvpn.image_id
restart = "always"
ports {
external = 6881
internal = 6881
ip = "0.0.0.0"
protocol = "tcp"
}
ports {
external = 6881
internal = 6881
ip = "0.0.0.0"
protocol = "udp"
}
ports {
external = 8080
internal = 8080
ip = "0.0.0.0"
protocol = "tcp"
}
ports {
external = 8118
internal = 8118
ip = "0.0.0.0"
protocol = "tcp"
}
## Environment variables https://github.com/binhex/arch-qbittorrentvpn
env = ["VPN_ENABLED=yes", "VPN_USER=${var.vpn_user}", "VPN_PASS=${var.vpn_pass}", "VPN_PROV=${var.vpn_prov}", "VPN_CLIENT=wireguard", "STRICT_PORT_FORWARD=${var.port_forward}", "ENABLE_PRIVOXY=no", "WEBUI_PORT=8080", "LAN_NETWORK=${var.lan_network}", "NAME_SERVERS=84.200.69.80,37.235.1.174,1.1.1.1,37.235.1.177,84.200.70.40,1.0.0.1", "DEBUG=false", "UMASK=000", "PUID=0", "PGID=0"]
volumes {
container_path = "/config"
host_path = "${var.appdata_prefix}/qbittorrentvpn"
}
## Path to downloads folder
volumes {
container_path = "/data"
host_path = "${var.media_prefix}/downloads"
}
volumes {
container_path = "/etc/localtime"
host_path = "/etc/localtime"
read_only = true
}
capabilities {
add = ["NET_ADMIN"]
}
sysctls = ({
"net.ipv4.conf.all.src_valid_mark" = "1"
})
privileged = true
}