Skip to content

Commit ed00549

Browse files
committed
πŸ’€ Let the crew know: build yer own privateerr if GHCR be sunk
1 parent 00245b4 commit ed00549

File tree

6 files changed

+81
-29
lines changed

6 files changed

+81
-29
lines changed

β€Ž.github/workflows/main.ymlβ€Ž

Lines changed: 0 additions & 12 deletions
This file was deleted.
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
name: Validate Docker Compose
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
paths:
8+
- 'docker-compose.yml'
9+
- '.github/workflows/validate-compose.yml'
10+
11+
jobs:
12+
validate-docker-compose:
13+
runs-on: ubuntu-latest
14+
permissions:
15+
contents: read
16+
17+
steps:
18+
- name: Checkout code
19+
uses: actions/checkout@v4
20+
21+
- name: Install Docker Compose
22+
uses: ndeloof/install-compose-action@v0.0.1
23+
24+
- name: Validate Docker Compose configuration
25+
run: docker-compose config --no-interpolate

β€ŽREADME.mdβ€Ž

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -125,9 +125,22 @@ docker run --rm --network=container:gluetun-latest alpine:3.18 sh -c "apk add wg
125125
}
126126
```
127127

128-
> [!CAUTION]
128+
> [!WARNING]
129129
> ⚠️☠️ Ye should see an IP that ain't from yer home port. If not, batten down and check yer `.env` scroll.
130130
131+
> [!NOTE]
132+
> πŸ΄β€β˜ οΈ The `privateerr` image be used to generate the sacred PIA WireGuard config scroll that powers yer Gluetun VPN sails. By default, Plundarr pulls this image straight from GitHub Container Registry (GHCR), no buildin' required.
133+
>
134+
> But if the winds be against yeβ€”or ye fancy testin' custom changesβ€”ye can chart a local build instead using the `docker-compose.build.yml` override scroll.
135+
>
136+
> To build `privateerr` locally:
137+
>
138+
> ```bash
139+
> docker-compose -f docker-compose.yml -f docker-compose.build.yml up --build
140+
> ```
141+
>
142+
> This override be swappin' the pull fer a local build usin' yer own Dockerfile and variables from the `.env` scroll. Use it when the registry be unreachable or ye need to tinker with the hull below deck.
143+
131144
## Navigatin' Troubled Waters ☠️🌊
132145
133146
> [!TIP]
@@ -173,7 +186,7 @@ Plundarr has been tested on Synology DS1522+ and DS916+ runnin' DSM 7.2. But fea
173186
174187
## Articles of Agreement βš–οΈ
175188
176-
> [!WARNING]
189+
> [!CAUTION]
177190
> πŸ΄β€β˜ οΈβš–οΈ Mind the legal seas! Ye must honor both the Apache 2 License and the MIT License, or be prepared to walk the plank.
178191
179192
This project be licensed under the Apache 2 Licenseβ€”see the [LICENSE](LICENSE) scroll for details.

β€Ždocker-compose.build.ymlβ€Ž

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
---
2+
#
3+
# docker-compose.build.yml: Optional override Compose file for local builds.
4+
#
5+
# This file defines an alternate configuration for the `privateerr` service.
6+
# Instead of pulling the pre-built image from GitHub Container Registry,
7+
# this configuration builds the container locally from source using the
8+
# provided Dockerfile and build arguments.
9+
#
10+
# Use this file when testing local changes or if the image is unavailable from GHCR.
11+
#
12+
# To activate:
13+
# docker-compose -f docker-compose.yml -f docker-compose.build.yml up --build
14+
#
15+
# Service included:
16+
# - privateerr: https://github.com/scottgigawatt/privateerr
17+
#
18+
19+
#
20+
# Define the services section
21+
#
22+
services:
23+
#
24+
# Define the 'privateerr' service as a local build override for use when image cannot be pulled from GHCR
25+
#
26+
privateerr:
27+
build: # Build to install required packages
28+
context: config/privateerr/docker # Docker build context
29+
dockerfile: Dockerfile # Dockerfile to use for the build
30+
args: # Build arguments passed to Dockerfile
31+
PRIVATEERR_BASE_IMAGE: ${PRIVATEERR_BASE_IMAGE} # Specify build argument for FROM base image
32+
PRIVATEERR_BASE_TAG: ${PRIVATEERR_BASE_TAG} # Specify build argument for FROM base image tag
33+
TZ: ${TZ} # Specify build argument for time zone
34+
PIA_APP_HOME: ${PIA_APP_HOME} # Specify build argument for PIA scripts path

β€Ždocker-compose.ymlβ€Ž

Lines changed: 6 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -75,23 +75,15 @@ services:
7575
#
7676
privateerr:
7777
# Docker image build and container information
78-
image: ${PRIVATEERR_IMAGE}:${PRIVATEERR_TAG} # Set build image name and tag
79-
build: # Build to install required packages
80-
context: config/privateerr/docker # Docker build context
81-
dockerfile: Dockerfile # Dockerfile to use for the build
82-
args: # Build arguments passed to Dockerfile
83-
PRIVATEERR_BASE_IMAGE: ${PRIVATEERR_BASE_IMAGE} # Specify build argument for FROM base image
84-
PRIVATEERR_BASE_TAG: ${PRIVATEERR_BASE_TAG} # Specify build argument for FROM base image tag
85-
TZ: ${TZ} # Specify build argument for time zone
86-
PIA_APP_HOME: ${PIA_APP_HOME} # Specify build argument for PIA scripts path
87-
container_name: privateerr-${PRIVATEERR_TAG} # Append Docker image tag to container name
88-
restart: "no" # Do not restart the container once it exits
89-
hostname: privateerr # Set the container hostname
90-
privileged: true # Run with full host privileges
78+
image: ${PRIVATEERR_IMAGE}:${PRIVATEERR_TAG} # Pull image (use docker-compose.build.yml for local build override)
79+
container_name: privateerr-${PRIVATEERR_TAG} # Append Docker image tag to container name
80+
restart: "no" # Do not restart the container once it exits
81+
hostname: privateerr # Set the container hostname
82+
privileged: true # Run with full host privileges
9183

9284
# Add container labels
9385
labels:
94-
- "com.centurylinklabs.watchtower.enable=false" # Exclude local init container from Watchtower
86+
- "com.centurylinklabs.watchtower.enable=false" # Exclude init container from Watchtower
9587

9688
# Define the container environment
9789
environment:

β€Žexample.envβ€Ž

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ TZ="${TZ:-America/New_York}"
4545
#
4646
PRIVATEERR_BASE_IMAGE="${PRIVATEERR_BASE_IMAGE:-ubuntu}"
4747
PRIVATEERR_BASE_TAG="${PRIVATEERR_BASE_TAG:-20.04}"
48-
PRIVATEERR_IMAGE="${PRIVATEERR_IMAGE:-scottgigawatt/privateerr}"
48+
PRIVATEERR_IMAGE="${PRIVATEERR_IMAGE:-ghcr.io/scottgigawatt/privateerr}"
4949
PRIVATEERR_TAG="${PRIVATEERR_TAG:-latest}"
5050
PRIVATEERR_WIREGUARD_CONFIG="${PRIVATEERR_WIREGUARD_CONFIG:-./config/gluetun/wireguard/wg0.conf}"
5151

0 commit comments

Comments
Β (0)