Last active 1 month ago Unlisted

Since there's some blocking going on with a certain German host

Revision f6b876478b136bdf903bacb662377476dcbc2ecc

docker-compose.yml Raw
1services:
2 vpn:
3 container_name: plex-vpn
4 image: jordanpotter/wireguard
5 cap_add:
6 - NET_ADMIN
7 - SYS_MODULE
8 sysctls:
9 net.ipv4.conf.all.src_valid_mark: 1
10 net.ipv6.conf.all.disable_ipv6: 0
11 volumes:
12 ## Your WireGuard configuration file. Can be from any provider that allows you to generate WireGuard configurations for connections (e.g. Mullvad, AirVPN)
13 ## The VPN service does not need to support port forwarding.
14 - ./my-vpn-provider.conf/etc/wireguard/vpn.conf
15 ports:
16 ## Expose the Plex port locally, so the host can reverse proxy it. In my case I have NGINX installed directly on the host, and I basically just: `proxy_pass http://127.0.0.1:32400;`
17 ## If you run NGINX Proxy Manager or similar, you will likely have to figure out slightly different solution
18 ## This will allow you to serve streaming traffic between your Plex server and your users, directly from the Hetzner server. It's only using the VPN for "calling home" from Plex media server (the software) to Plex.tv servers (the Plex company's servers).
19 - "127.0.0.1:32400:32400"
20 restart: unless-stopped
21
22 plex:
23 image: plexinc/pms-docker:latest
24 container_name: plex
25 depends_on:
26 - vpn
27 ## The important line, makes all network traffic for the Plex container go through the VPN container.
28 network_mode: "service:vpn"
29 environment:
30 ## I don't actually remember if these are necessary lmao
31 - PUID=1000
32 - PLEX_UID=1000
33 - PGID=1000
34 - PLEX_GID=1000
35 - VERSION=docker
36 ## Claim token, if needed
37 # - PLEX_CLAIM=claim-rr-blah-blah-blah
38 volumes:
39 ## Plex configuration/logs/etc.
40 - ./config:/config
41
42 ## Change this to where you have your media stored.
43 - /data/media:/media
44 restart: unless-stopped
45 ## Expose the [i]GPU to the container. For hardware transcoding
46 devices:
47 - /dev/dri:/dev/dri