Matomo docker compose
Jump to navigation
Jump to search
make folder:
mkdir matomo touch matomo/docker-compose.yml
Create a docker-compose.yml file similar to this:
version: "3" services: db: image: mariadb:10.11 command: --max-allowed-packet=64MB restart: always volumes: - db:/var/lib/mysql:Z environment: - MYSQL_ROOT_PASSWORD=password123* - MARIADB_AUTO_UPGRADE=1 - MARIADB_DISABLE_UPGRADE_BACKUP=1
app: image: matomo restart: always volumes: - matomo:/var/www/html:z environment: - MATOMO_DATABASE_HOST=db ports: - 8080:80
volumes: db: matomo:
Open a new .env file with nano:
nano .env
You’ll need to fill in a user name and password, as well as a strong password for the MariaDB root superuser account:
MARIADB_USER=matomo MARIADB_PASSWORD=a_strong_password_for_user MARIADB_ROOT_PASSWORD=a_strong_password_for_root
Bring up your stack by running
docker-compose up -d
Log in to the Admin UI
http://localhost:8080
Now you’ll be on the Database Setup page:
databaSareve: db