I successfully installed Matomo on CyberPanel, but cannot solve one last issue, cron. Installation is as:
cd /home/matomo.mydomain.com/matomo
wget https://builds.matomo.org/matomo-latest.zip && unzip matomo-latest.zip
cp -ar matomo/* .
rm -rf matomo-latest.zip 'How to install Matomo.html' matomo
chown -R cyberpanel:cyberpanel /home/matomo.mydomain.com/matomo
chmod -R 755 /home/matomo.mydomain.com/matomo
So, in ‘normal’ (GCP Marketplace deployment image), I have for /etc/cron.d/matomo-archive:
MAILTO="myemail@mydomain.com"
5 * * * * root /usr/bin/php /var/www/html/console core:archive --url=https://matomo.mydomain.com/matomo/ > /home/files/matomo-archive.log
and working
su root -s /bin/bash -c "/usr/bin/php /var/www/html/console core:archive --url=https://matomo.mydomain.com/matomo/"
On CyberPanel installation for /etc/cron.d/matomo-archive, I set:
MAILTO="myemail@mydomain.com"
5 * * * * root /usr/bin/php /home/matomo.mydomain.com/matomo/console core:archive --url=https://matomo.mydomain.com/matomo/ > /home/files/matomo-archive.log
but output is bad and cron actually not working (so, I have for):
su root -s /bin/bash -c "/usr/bin/php /home/matomo.mydomain.com/matomo/console core:archive --url=https://matomo.mydomain.com/matomo/"
output as
#!/usr/bin/env php
So, it looks that something is wrong with my paths (I guess to console).
Does anyone understand what I did wrong?
2 posts - 2 participants