Compare commits

..

No commits in common. "39920fd1e61ff2754446a2e681c2e6d31df0c36f" and "ce58685691275d4a54b69f68b173ddbb1f2a4d7d" have entirely different histories.

3 changed files with 1 additions and 62 deletions

View File

@ -12,7 +12,7 @@ Kubernetes has simply too much overhead for a small home lab like mine. I'm usin
The only thing that would make me change idea would be a need for autoscaling, but I'm still far from that situation. The only thing that would make me change idea would be a need for autoscaling, but I'm still far from that situation.
### How do I use this? ### How do I use this?
The `caddy-docker-proxy` is the first container that should be started, after running `$ docker network create caddy` to ensure the external network exists on the system. The `Caddyfile` included and mounted in `/etc/caddy/Caddyfile` is used in this case to give access to the air-gapped comtainers running on different machines on the same network. An example is found in the [Caddyfile](https://gitea.oddone.dev/Doddophonique/compose-personal-stack/src/branch/caddy-revamp/caddy-docker-proxy/Caddyfile), where the [Memos](https://gitea.oddone.dev/Doddophonique/compose-personal-stack/src/branch/caddy-revamp/memos/docker-compose.yml) container is exposed. The `caddy-docker-proxy` is the first container that should be started, after running `$ docker network create caddy` to ensure the external network exists on the system. The `Caddyfile` included and mounted in `/etc/caddy/caddyfile` is used in this case to give access to the air-gapped comtainers running on different machines on the same network.
As you can see, this is a borderline situation where some people may prefer having service discovery with either Swarm or Kubernetes, but in my experience this is still not enough to call for that. As you can see, this is a borderline situation where some people may prefer having service discovery with either Swarm or Kubernetes, but in my experience this is still not enough to call for that.
### Conclusion (for now): ### Conclusion (for now):

View File

@ -11,11 +11,3 @@ subdomain.domain.tld {
} }
log log
} }
# This is an example based on the docker-compose.yml contained
# in the memos folder
memos.domain.tld {
reverse_proxy 192.168.1.128:9000
encode zstd gzip
log
}

View File

@ -1,53 +0,0 @@
---
x-logging:
&default-logging
driver: syslog
options:
tag: "container_name/{{.Name}}"
labels: "LABEL"
syslog-facility: local7
x-opt-values:
&volume-opt
driver_opts: &options
type: "nfs"
o: "addr=${IP},rw"
services:
memos:
image: neosmemo/memos:stable
container_name: memos
# Use labels if this container is hosted on the same machine as
# the Caddy reverse proxy
labels:
caddy: ${MEMOS_HOSTNAME}
caddy.log:
caddy.encode: "zstd gzip"
caddy.reverse_proxy: "{{upstreams 5230}}"
restart: unless-stopped
# This is not needed if labels are used. If this container is
# hosted on a different machine under the same subnetwoork, use
# its private IP address instead of 192.168.1.128. Check the
# Caddyfile inside caddy-docker-proxy folder for an example
# on how to forward traffic to this container
#
# ports:
# - "192.168.1.128:9000:5230"
volumes:
- /mnt/path:/var/opt/memos
networks:
- caddy
logging: *default-logging
# Optional, needed if you are using an NFS server
#
# volumes:
# volume:
# <<: *volume-opt
# driver_opts:
# <<: *options
# device: ":/mnt/path"
networks:
caddy:
external: true