1、安装PHP
https://www.jianshu.com/p/8d54a401ec06
yum remove php* yum -y install epel-release rpm -Uvh https://mirror.webtatic.com/yum/el7/webtatic-release.rpm yum -y install php72w* --skip-broken systemctl start php-fpm.service
2、安装mysql,并新建matomo数据库
3、安装nginx
https://www.jianshu.com/p/0626bbd975f3
yum install -y nginx [root@test conf.d]# cat /etc/nginx/conf.d/matomo.conf |grep -Ev "^%|^$" server { listen 80; server_name test.matomo.cn; root /opt/matomo; index index.php; access_log /var/log/nginx/access.log main; error_log /var/log/nginx/error.log warn; location / { try_files $uri /index.php$is_args$args; } location ~ .php$ { try_files $uri =404; include fastcgi_params; fastcgi_pass 127.0.0.1:9000; fastcgi_index index.php; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; } }
nginx -t
systemctl start nginx.service
systemctl enable nginx.service
浏览器输入 test.matomo.cn
参考: https://matomo.org/what-is-matomo/
https://www.douban.com/note/691897375/