Feat: basic matomo deployement

This commit is contained in:
Bertrand Benjamin 2022-02-20 09:35:39 +01:00
parent 54332dc361
commit 8fa797a362
3 changed files with 48 additions and 0 deletions

3
.gitignore vendored
View File

@ -6,3 +6,6 @@ traefik/certs/
traefik/log/
minio/data
matomo/html/
matomo/db/

11
matomo/.env Normal file
View File

@ -0,0 +1,11 @@
MATOMO_DATABASE_HOST=db
MATOMO_DATABASE_ADAPTER=mysql
MATOMO_DATABASE_TABLES_PREFIX=matomo_
MATOMO_DATABASE_USERNAME=MYUSER
MATOMO_DATABASE_PASSWORD=MYPASSWORD
MATOMO_DATABASE_DBNAME=MYDATABASE
MYSQL_PASSWORD=$MATOMO_DATABASE_PASSWORD
MYSQL_DATABASE=$MATOMO_DATABASE_DBNAME
MYSQL_USER=$MATOMO_DATABASE_USERNAME

34
matomo/docker-compose.yml Normal file
View File

@ -0,0 +1,34 @@
version: "3.7"
services:
db:
image: mariadb:10
command: --max-allowed-packet=64MB
volumes:
- ./db:/var/lib/mysql
environment:
MYSQL_RANDOM_ROOT_PASSWORD: 'yes'
env_file:
- ./.env
networks:
- matomo
matomo:
image: matomo:latest
volumes:
- ./html:/var/www/html
env_file:
- ./.env
labels:
- "traefik.enable=true"
- "traefik.http.routers.matomo.rule=Host(`matomo.combava.lan`)"
- "traefik.http.routers.matomo.entrypoints=https"
- "traefik.http.routers.matomo.tls=true"
- "traefik.http.services.matomo.loadbalancer.server.port=80"
networks:
- matomo
- gateway
networks:
matomo:
gateway:
external: true