Twin caddy instance config?

cut parts of the template that were not needed

1. The problem I’m having:

I am trying to have two caddy servers sitting adjacent to eachother with near-zero cross config needed

3. Caddy version:

v2.8.4 h1:q3pe0wpBj1OcHFZ3n/1nl4V4bxBrYoSoab7rL9BMYNk=
Specifically lucaslorentz/caddy-docker-proxy:ci-alpine docker

4. How I installed and ran Caddy:

Docker with a compose file,

a. System environment:

Docker Compose

c. Service/unit/compose file:

caddy:
    image: lucaslorentz/caddy-docker-proxy:ci-alpine
    container_name: caddy
    restart: unless-stopped
    dns:
      - "8.8.8.8"
    networks:
      - core
      - webserver
    extra_hosts: ["host.docker.internal:host-gateway"]
    ports:
      - 80:80
      - 443:443
    environment:
      CADDY_ADMIN: ":2019"
      CADDY_INGRESS_NETWORKS: webserver
      CADDY_DOCKER_CADDYFILE_PATH: /srv/caddy.conf
    volumes:
      - caddy_conf:/config
      - caddy_data:/data
      - /var/run/docker.sock:/var/run/docker.sock

      - ./caddy/caddy.conf:/etc/caddy/Caddyfile
      - ./caddy:/srv

      - /docker/:/mnt
      - /drop-reg:/drop-reg

  php-fpm:
    image: "php:8.3-fpm"
    container_name: php-fpm
    user: "1000:1000"
    restart: unless-stopped
    volumes_from:
      - caddy
    networks:
      - core

I am trying to setup a second domain that can be managed independantly from the main domain, however both are sitting on the same server and I would like to not have to restart main.tld’s webserver (currently the config I sent above) whenver I need to update secondary.tld’s webserver config. which is currently loaded through an import rule

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.