mirror of
https://github.com/PAPAMICA/docker-compose-collection.git
synced 2026-03-18 21:30:41 +01:00
55 lines
1.8 KiB
YAML
55 lines
1.8 KiB
YAML
# Docker-compose mis à disposition par Mickael "PAPAMICA" Asseline
|
|
# Date de mise à jour : 27/10/2020
|
|
|
|
# Variables d'environnement à déclarer :
|
|
# - SERVICE : nom du service (exemple : plex)
|
|
# - DATA_LOCATION : localisation des données (exemple /apps/"service")
|
|
# - URL_LOKI : lien du serveur loki (exemple : ndd/loki/api/v1/push)
|
|
# - NDD : lien du nom de domaine (exemple : papamica.fr)
|
|
# - DATA : localisation de vos fichiers à explorer
|
|
|
|
# Fonctionne avec Portainer
|
|
version: "2"
|
|
|
|
services:
|
|
# FileBrowser : https://github.com/filebrowser/filebrowser
|
|
filebrowser:
|
|
image: filebrowser/filebrowser:latest
|
|
container_name: $SERVICE
|
|
restart: always
|
|
volumes:
|
|
- $DATA:/srv
|
|
- $DATA_LOCATION/config.json:/config.json
|
|
- $DATA_LOCATION/database.db:/database.db
|
|
# ports:
|
|
# - 8080:80
|
|
healthcheck:
|
|
test: wget -nv -t1 --spider 'http://localhost:80'
|
|
interval: 1m
|
|
timeout: 30s
|
|
retries: 3
|
|
|
|
|
|
networks:
|
|
- proxy
|
|
logging:
|
|
driver: loki
|
|
options:
|
|
loki-url: "$URL_LOKI"
|
|
loki-external-labels: service={{.Name}}
|
|
labels:
|
|
- "traefik.enable=true"
|
|
- "traefik.http.routers.$SERVICE.entrypoints=http"
|
|
- "traefik.http.routers.$SERVICE.rule=Host(`$SERVICE.$NDD`)"
|
|
- "traefik.http.middlewares.$SERVICE-https-redirect.redirectscheme.scheme=https"
|
|
- "traefik.http.routers.$SERVICE.middlewares=$SERVICE-https-redirect"
|
|
- "traefik.http.routers.$SERVICE-secure.entrypoints=https"
|
|
- "traefik.http.routers.$SERVICE-secure.rule=Host(`$SERVICE.$NDD`)"
|
|
- "traefik.http.routers.$SERVICE-secure.tls=true"
|
|
- "traefik.http.routers.$SERVICE-secure.tls.certresolver=http"
|
|
- "traefik.docker.network=proxy"
|
|
|
|
networks:
|
|
proxy:
|
|
external:
|
|
name: proxy |