From 2bc8f85df11f172a200871ac98b617b54e68eabf Mon Sep 17 00:00:00 2001 From: hcornet Date: Mon, 23 Dec 2024 19:01:51 +0100 Subject: [PATCH] first sync --- config/config.yaml | 8 +++++++ docker-compose.yml | 55 +++++++++++++++------------------------------- macvlan | 5 +++++ 3 files changed, 31 insertions(+), 37 deletions(-) create mode 100644 config/config.yaml create mode 100644 macvlan diff --git a/config/config.yaml b/config/config.yaml new file mode 100644 index 0000000..5499d79 --- /dev/null +++ b/config/config.yaml @@ -0,0 +1,8 @@ +tunnel: 00000000-1111-2222-3333-444444444444 +credentials-file: /home/nonroot/.cloudflared/00000000-1111-2222-3333-444444444444.json +logfile: /var/log/cloudflared.log + +ingress: + - hostname: whoami.tips-of-mine.com + service: http://whoami:7878 + - service: http_status:404 diff --git a/docker-compose.yml b/docker-compose.yml index 4054566..72f67be 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -1,42 +1,23 @@ #### NETWORKS -networks: - traefik_front_network: - external: true - back_network_: - driver: bridge - attachable: true +#networks: +# macvlan4: +# external: true #### SERVICES services: -### hello_world - hello_world: - container_name: gitea-app - hostname: gitea-app - image: hello-world - environment: - restart: always - networks: -# - back_network_gitea - - traefik_front_network + tunnel: + container_name: cloudflared-tunnel + hostname: cloudflared-tunnel + image: cloudflare/cloudflared:latest + restart: unless-stopped + command: tunnel run volumes: - labels: - - "traefik.enable=true" - - "traefik.docker.network=traefik_front_network" -# HTTP - - "traefik.http.routers.hello-world-http.rule=Host(`hello-world.tips-of-mine.com`)" - - "traefik.http.routers.hello-world-http.entrypoints=http" - - "traefik.http.routers.hello-world-http.priority=49" -# HTTPS - - "traefik.http.routers.hello-world-https.rule=Host(`hello-world.tips-of-mine.com`)" - - "traefik.http.routers.hello-world-https.entrypoints=https" - - "traefik.http.routers.hello-world-https.tls=true" - - "traefik.http.routers.hello-world-https.priority=50" - - "traefik.http.routers.gitea.service=gitea-https-service" -# Middleware -# Service -# - "traefik.http.services.gitea-https-service.loadbalancer.server.port=3000" -# - "traefik.http.services.gitea-https-service.loadbalancer.server.scheme=https" -# - "traefik.http.services.gitea-https-service.loadbalancer.healthcheck.hostname=gitea.traefik.me" -# - "traefik.http.services.gitea-https-service.loadbalancer.healthcheck.method=foobar" -# - "traefik.http.services.gitea-https-service.loadbalancer.healthcheck.timeout=10" -# - "traefik.http.services.gitea-https-service.loadbalancer.healthcheck.interval=30" + - "/etc/localtime:/etc/localtime:ro" +# - "./config:/home/nonroot/.cloudflared/" +# restart: always + environment: + - TZ=Europe/Paris + - TUNNEL_TOKEN=000000000000000000000000000000000000000000000000000000000000000000000000000000 +# networks: +# macvlan4: # change name to whatever you like +# ipv4_address: 10.0.4.20 # change to your IP in your vLAN subnet diff --git a/macvlan b/macvlan new file mode 100644 index 0000000..de7623b --- /dev/null +++ b/macvlan @@ -0,0 +1,5 @@ +docker network create -d macvlan \ + --subnet=10.0.4.0/24 \ + --gateway=10.0.4.1 \ + -o parent=eth0.4 \ + macvlan4