diff --git a/Readme.md b/Readme.md index a970279..41d3273 100644 --- a/Readme.md +++ b/Readme.md @@ -11,6 +11,20 @@ cp config.env.tmpl config.env cp Caddyfile.tmpl Caddyfile ``` +## Connecting services + +Add the `proxy.network` to the service you would like to proxy. This can be done by either editing the quadlet directly or creating a systemd override like so: + +1. Create a folder next to the container/pod file: `$name.$type.d/` (e.g. `nginx.container.d/`) +2. Create a config file (e.g. `proxy.conf`) in this folder with the following contents: +```yaml +[Container] +Network=proxy.network +``` + +> [!TIP] +> The config is also available to copy under `assets/proxy-network.conf`! + ## Firewall settings ```bash diff --git a/assets/proxy-network.conf b/assets/proxy-network.conf new file mode 100644 index 0000000..b509fa0 --- /dev/null +++ b/assets/proxy-network.conf @@ -0,0 +1,4 @@ +# Add this to the $NAME.container.d/ folder + +[Container] +Network=proxy.network diff --git a/caddy.container b/caddy.container index 24f75df..959ff6c 100644 --- a/caddy.container +++ b/caddy.container @@ -9,6 +9,7 @@ PublishPort=8443:443 Volume=./Caddyfile:/etc/caddy/Caddyfile:ro,Z Volume=caddy-data:/data Volume=caddy-config:/config +Network=proxy.network Secret=desec-token,type=env,target=DESEC_TOKEN diff --git a/proxy.network b/proxy.network new file mode 100644 index 0000000..8307ea7 --- /dev/null +++ b/proxy.network @@ -0,0 +1,2 @@ +[Network] +NetworkName=proxy \ No newline at end of file