Тип сервиса
Сервис Matomo
Среда выполнения PHP для самостоятельно размещаемой веб-аналитики Matomo со сборкой из совместимого репозитория приложения.
Вы добавляете этот сервис в стек и выбираете там его версию и ресурсы. Каждое окружение может их переопределить.
На этой странице
В StackMaster
Как Matomo работает в StackMaster
Image
The service runs the prebuilt wodby/matomo Apache image: Matomo's release, verified against its signature, on the Apache variant of wodby/php. Apache serves Matomo and passes PHP to PHP-FPM in the same container, on port 80. There is no build and no Git repository; a new image revision of the selected Matomo major brings Matomo's updates.
Plugins can be installed from Matomo's Marketplace. They are kept on the files volume, so every replica loads them and they survive new images.
Settings
Matomo writes its settings to config/config.ini.php. The image also writes config/common.config.ini.php on every start, a layer Matomo reads but never writes:
- Database.
DB_HOST,DB_PORT,DB_NAME,DB_USERNAMEandDB_PASSWORDfrom thedblink, with thematomo_table prefix. The password is never copied intoconfig.ini.php. - Salt.
MATOMO_SALT, generated once for the app. It is mixed into every password hash, API token and session: never change it. - Trusted hosts. Every route of the app (
WODBY_HOSTS). - Proxy. HTTPS when the main route uses it, and the client address from
X-Forwarded-For, because TLS ends before the request reaches the container. - Installer and updates. The web installer and Matomo's own updater are off; the image brings the code.
- Archiving. Reports are archived by the hourly cron job, not when someone views them.
Data
The files volume is mounted at /mnt/files and shared by every replica and the cron job through the linked storage service. It holds config.ini.php (plugin activation and every setting saved in Matomo), custom logos (misc/user) and Marketplace plugins. Matomo's cache stays in each container. The database holds reports, visits and users; sessions are kept in the database.
Installation and updates
On every deployment the Install or update Matomo action runs matomo-update in a job of the new version, before its pods are replaced (on the first deployment, right after the install):
- First deployment: it installs Matomo into the empty database, as the web installer would. The superuser comes from the service's settings:
admin-username(defaultadmin,MATOMO_ADMIN_USERNAME),admin-password(required, secret,MATOMO_ADMIN_PASSWORD) andadmin-email(required,MATOMO_ADMIN_EMAIL). Whenwebsite-url(MATOMO_SITE_URL) is set, the first website is added with the app's title as its name; otherwise Matomo asks for a website at the first sign-in. - Without an admin password or email, the action fails and installs nothing.
- The installation never runs over existing tables: if the database has tables but
config.ini.phpis missing, the action fails instead. - Later deployments: it runs
php console core:update --yes. The previous version keeps serving on the updated database until the new one is ready. If the update fails, the deployment stops before the rollout. - Changing the admin settings after the first deployment does not change the account; change it in Matomo.
Archiving
The archive cron job runs php console core:archive at five past every hour. It also sends scheduled email reports and runs Matomo's other scheduled tasks.
Limits
- Matomo 5 on PHP 8.4, with MariaDB or MySQL.
- Plugins that change the tracker script
matomo.jsrebuild it in the container where they run; restart the service after activating one so every replica serves the new script. - No development workspace.
Check the result
- Administration > System > Diagnostics shows Matomo's own checks.
php console diagnostics:runreports the state of the installation.- The deployment's log shows the install or update output, and the cron job's log the archiving.
Обзор
Технический профиль Matomo
Версии
Репозиторий исходного кода
Публичный Helm-чарт
Постоянные тома
Стеки
Стеки, в которые входит Matomo
Конфигурация
Конфигурация сервиса Matomo
Технические домены
Тома
Настройки
Расписания cron
Действия
Связи сервиса
Каждая связь — это подключение Matomo к другому сервису. На какой сервис указывает связь, задаёт стек. На карточках перечислены публичные сервисы, которые подходят для каждой связи.
db
Сервисы, которые подходят для этой связи
files
Сервисы, которые подходят для этой связи
sendmail
Сервисы, которые подходят для этой связи
На основе этого сервиса