forked from pool/matomo
Eric Schirra
ee7c8b91c5
- Update: 3.13.0 * matomo-org/matomo #15030 Adds links to online guides in reports help [by @sgiehl, @diosmosis] #4519 Segment by Product Category, Product name, Product SKU, Product prices [by @diosmosis] #15049 More efficient heart beat timer [by @tsteur] #10439 After updating the 2019_01 archive blob tables are gaining size [by @diosmosis] #15086 Auto Archiving falls back to DEFAULT_DATE_LAST even if last archiving ran until completion [by @katebutler, @diosmosis] #10765 Write a User guide for Custom alerts [by @mattab] #14835 Page Overlay – JavaScript Error – TypeError: location.match(…) is null [by @diosmosis] #15101 Matomo 3.12.0 missing Action in Proxy module #15044 Slight performance improvement when rendering data table visualisations [by @tsteur, @diosmosis] #15000 _pk_testcookies set while using “disableCookies” [by @tsteur] #15070 Matomo 3.12 doesn’t work with open_basedir restrictions [by @tsteur] #15078 Integrity check issue in Matomo 3.12.0 #15093 Fix reports by dimensions layout [by @sgiehl, @diosmosis] #15102 Fix Insight visualization layout [by @sgiehl, @tsteur] #15151 E-Mail reports date range error [by @diosmosis] #14945 In Comparison mode, numbers are not formatted (thousands separator) [by @katebutler] #14821 Make Matomo compatible with PHP 7.4 [by @diosmosis] #10373 Excluding IPs doesn’t work on php7 #14623 Update message creates empty space in admin and pushes widgets down #14714 JS Tracker: setUserId and addEcommerceItem sku should work when User ID is a number [by @tsteur] #15080 Comparison feature displays segment definition instead of segment name when segmenting action based custom dimensions [by @diosmosis] #15103 Ensure insight reports uses the correct compare period number for periods other than day [by @sgiehl, @tsteur] #15140 [automatic translation update] Updated 173 strings in 10 languages (es-ar, de, el, nl, pl, pt-br, pt, sq, zh-cn, zh-tw) [by @sgiehl] #15195 [automatic translation update] Updated 160 strings in 6 languages (fr, it, ja, lt, pt-br, tr) [by @sgiehl] #12816 Rename “Clicked URL” dimension to “Clicked Outlink” [by @katebutler] #14360 UserID no longer overwrites VisitorId [by @MichaelHeerklotz, @diosmosis] #14827 German title HTML entity encoded [by @sgiehl] #15026 Use thousands separator in single metric view [by @katebutler, @tsteur] #15032 Some overlay improvements [by @tsteur, @diosmosis] #15037 Prevent warning array to string conversion in console renderer [by @tsteur, @diosmosis] #15055 Updates device detector to 3.12.1 [by @sgiehl, @diosmosis] #15057 Prevent notice in tracker code generator [by @tsteur, @diosmosis] #15066 Avoid ‘Trying to add two strings in DataTable\Row::sumRowArray’ warning in SEO API [by @sgiehl, @diosmosis] #15079 Revert umlaut icons [by @Findus23, @tsteur] #15087 3.12.0 (3.12.0-b4 and up) is broken on NixOS #15088 Rename “Clicked URL” dimension to “Clicked Outlink” [by @katebutler, @diosmosis] #15090 Made a few minor grammar changes to the README.md [by @ALucatero03, @tsteur] #15095 Fix zend session hides actual error when there are two or more errors… [by @tsteur] #15098 Invert change comparison when displaying percents in the UI … [by @diosmosis] #15110 Fixes a couple segment handling regressions in the UI [by @diosmosis] #15113 Document that Matomo won’t work with a MySQL load balancer such as ProxySQL unless… [by @mattab] #15114 Better detection of a succesfull start of a session [by @tsteur, @diosmosis] #15116 Show the link to upload a new plugin when enable_plugin_upload=1 [by @mattab, @diosmosis] #15129 Don’t freeze lefthand column of datatable on small screens [by @katebutler, @tsteur] #15147 Adds new event to define if lower metric values are better [by @sgiehl, @tsteur] #15152 Fix manual plugin upload process when Marketplace plugin is disabled [by @diosmosis, @tsteur] #15165 Update FAQ “How do I measure and get reports for my page sections / categories / mini-sites / languages?” to reflect how segment now work [by @tsteur] #15166 Fix socket configuration not applied in MySQLi [by @tsteur, @diosmosis] #15178 API reference doc: fix some of the example links [by @mattab, @diosmosis] #15183 Update spyc to 0.6.X [by @tsteur] #15187 Fix broken dashboard when a new version available and when multi_server_environment = 1 [by @mattab, @diosmosis] #15189 Support CliMulti on OS X and print note about whether CliMulti is used in archive output [by @diosmosis] * matomo-org/device-detector #5797 Did not catch “The Knowledge AI” #6070 Add 7 new crawlers and 3 feed readers [by @Kdecherf, @sgiehl] #6078 add new rules and tests for Nokia/Microsoft devices [by @mimmi20, @sgiehl] #6081 Detect devices for brands: Samsung, Vivo, iHunt, Huawei, Ritmix, Ross&Moor [by @sanchezzzhak, @sgiehl] #6083 Fail to Detect Meitu Device #6084 Added detect devices Meitu [by @sanchezzzhak, @sgiehl] #6085 Adds detection for Yandex Browser Lite and improves version detection for Yandex Browser [by @liviuconcioiu, @sgiehl] #6086 Adds detection for Shopify Partner bot [by @liviuconcioiu, @sgiehl] #6087 Added RestSharp library [by @wallin, @sgiehl] #6088 Improves detection for Vonino devices [by @liviuconcioiu, @sgiehl] #6092 Fix detection for AIS [by @liviuconcioiu, @sgiehl] #6093 Adds detection for Servo browser engine [by @liviuconcioiu, @sgiehl] #6096 Not Detecting OnePlus 7 Pro * matomo-org/component-network #4 Function getIPRangeBounds doesn’t always work on php7 [by @tsteur] #10 Validate CIDR range is 0..32 (IPv4) or 0..128 (IPv6); ref RFC-4632 [by @robocoder, @tsteur] #12 Test enhancement [by @peter279k, @tsteur] #13 Improving tests for IP class [by @peter279k, @tsteur] * matomo-org/tracker-proxy #57 Test enhancement [by @peter279k, @tsteur] * matomo-org/tag-manager #176 Adjustments for using TM and classic Tracking Code at the same time [by @MichaelHeerklotz, @tsteur] #184 Do not regenerate containers after core archiving [by @tsteur] #197 Use matomo.js and matomo.php as default if preferred [by @tsteur] #198 Convert empty date to null [by @tsteur] #199 fix: Tag::updateContainerTag setting a wrong startDate and endDate value [by @lockland, @tsteur] #202 Fix first trigger callback when tracker js is already loaded [by @MichaelHeerklotz, @tsteur] * matomo-org/matomo-log-analytics #251 Clarified usage of –token-auth=<SECRET> [by @cedwardsmedia, @tsteur] * matomo-org/matomo-php-tracker #44 Unlink userId and visitorId logic [by @MichaelHeerklotz, @diosmosis] #48 Fix wrong tracking url generated if tracker API endpoint already contains query search [by @tsteur, @diosmosis] #50 Regression: Wrong header is enabled only for GET. [by @diosmosis] * matomo-org/referrer-spam-blacklist #1143 Add 033nachtvandeliteratuur.nl [by @ericguirbal, @spmedia] #1145 Add 350+ spammer in bulk [by @Zodiac1978, @spmedia] #1146 Block billyblog.online [by @jonhenshaw, @spmedia] #1147 Update spammers.txt [by @spmedia] #1148 Add tammyblog.online [by @ericguirbal, @spmedia] #1149 Block monicablog.xyz [by @jonhenshaw, @spmedia] * matomo-org/component-ini #11 Test enhancement [by @peter279k, @tsteur] #12 Problem about IniReader::getFileContent method implementation OBS-URL: https://build.opensuse.org/request/show/756009 OBS-URL: https://build.opensuse.org/package/show/network:utilities/matomo?expand=0&rev=43
223 lines
9.2 KiB
RPMSpec
223 lines
9.2 KiB
RPMSpec
#
|
|
# spec file for package matomo
|
|
#
|
|
# Copyright (c) 2019 SUSE LLC
|
|
#
|
|
# All modifications and additions to the file contributed by third parties
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
# upon. The license for this file, and modifications and additions to the
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
# license for the pristine package is not an Open Source License, in which
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
# published by the Open Source Initiative.
|
|
|
|
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
|
#
|
|
|
|
|
|
# See also http://en.opensuse.org/openSUSE:Specfile_guidelines
|
|
|
|
%define apxs %{_sbindir}/apxs2
|
|
%define ap_sysconfdir %(%{apxs} -q SYSCONFDIR)
|
|
%define ap_serverroot %(%{apxs} -q PREFIX)
|
|
|
|
%if 0%{?suse_version}
|
|
%define ap_usr wwwrun
|
|
%define ap_grp www
|
|
%else
|
|
%define ap_usr nobody
|
|
%define ap_grp nogroup
|
|
%endif
|
|
|
|
Name: matomo
|
|
Version: 3.13.0
|
|
Release: 0
|
|
Summary: Web analytics platform
|
|
License: GPL-3.0-or-later
|
|
Group: Productivity/Networking/Web/Utilities
|
|
URL: http://matomo.org/
|
|
Source0: http://builds.matomo.org/%{name}-%{version}.tar.gz
|
|
Source2: %{name}.conf
|
|
Source3: %{name}.logrotate
|
|
Source4: %{name}-README.SUSE
|
|
Source10: %{name}-archive.cron
|
|
Source11: %{name}-archive.service
|
|
Source12: %{name}-archive.timer
|
|
Source13: %{name}.my.cnf
|
|
Source99: %{name}.rpmlintrc
|
|
BuildArch: noarch
|
|
%if 0%{?suse_version} >= 1500
|
|
Requires(pre): user(%ap_usr)
|
|
Requires(pre): group(%ap_grp)
|
|
%else
|
|
Requires(pre): aaa_base
|
|
%endif
|
|
BuildRequires: apache2-devel
|
|
BuildRequires: cron
|
|
BuildRequires: fdupes
|
|
BuildRequires: logrotate
|
|
BuildRequires: mariadb
|
|
#BuildRequires: php-json
|
|
#BuildRequires: php-mbstring
|
|
#BuildRequires: php-pdo
|
|
BuildRequires: systemd
|
|
BuildRequires: unzip
|
|
Requires: apache2
|
|
Requires: cron
|
|
Requires: logrotate
|
|
Requires: mariadb
|
|
Requires: mod_php_any >= 5.5.9
|
|
Requires: php-curl
|
|
Requires: php-gd
|
|
Requires: php-json
|
|
Requires: php-mbstring
|
|
Requires: php-mysql
|
|
Requires: php-pdo
|
|
%{?systemd_requires}
|
|
Recommends: php-geoip
|
|
Recommends: apache2-mod_geoip
|
|
|
|
Conflicts: piwik
|
|
|
|
%description
|
|
Matomo, formerly Piwik, is a web analytics platform that gives
|
|
insights into a website's visitors and marketing campaigns, so the
|
|
strategy and online experience of visitors may be optimized.
|
|
|
|
%prep
|
|
%setup -q -n matomo
|
|
install -m644 %{SOURCE4} README.SUSE
|
|
# remove unwanted files
|
|
find . -type f "(" -name .htaccess -o -name .travis.sh ")" -delete
|
|
#find . -name ".git*" -exec rm -Rf "{}" "+"
|
|
find . -type f "(" -name "*.c" -o -name "*.h" -o -name "*.js.orig" ")" -delete
|
|
# env-script-interpreter
|
|
find . -type f -exec sed -i -e 's|\/usr\/bin\/env php|\/usr\/bin\/php|g' {} +
|
|
|
|
#
|
|
# disable the auto updater, it can't work properly with the new, more secure permissions and is a bad idea on a RPM based setup anyways.
|
|
#
|
|
sed -i '/enable_auto_update/s/1$/0/' config/global.ini.php
|
|
|
|
#
|
|
# Fix integrity check triggered from fix of rpmlint errors.
|
|
# Drop moved files
|
|
for i in CHANGELOG.md CONTRIBUTING.md PRIVACY.md README.md SECURITY.md LEGALNOTICE LICENSE 'misc\/cron\/.htaccess' 'misc\/How to install Matomo.html' 'vendor\/tecnickcom\/tcpdf\/tools\/.htaccess' 'vendor\/twig\/twig\/ext\/twig\/php_twig.h' 'vendor\/twig\/twig\/ext\/twig\/twig.c' 'js\/piwik.js.orig'
|
|
do
|
|
sed -i "/\W\"${i}\"\W/d" config/manifest.inc.php
|
|
done
|
|
# Insert new hashes for chanded files
|
|
for file in console 'vendor/leafo/lessphp/plessc' 'vendor/tecnickcom/tcpdf/tools/tcpdf_addfont.php' 'config/global.ini.php'
|
|
do
|
|
size=$(ls -l $file | awk '{ print $5 }')
|
|
checksum=$(md5sum $file | awk '{ print $1 }')
|
|
file2=$(echo "$file" | sed 's/\//\\\//g')
|
|
sed -i "/\W\"$file2\"\W/c \"$file\" => array(\"$size\", \"$checksum\")," config/manifest.inc.php
|
|
done
|
|
|
|
%build
|
|
# nothing to build
|
|
|
|
%install
|
|
# make directories
|
|
install -d -m0755 %{buildroot}/%{ap_serverroot}/%{name}
|
|
install -d -m0755 %{buildroot}/%{ap_serverroot}/%{name}/tmp
|
|
install -d -m0755 %{buildroot}/%{_sysconfdir}/%{name}
|
|
install -d -m0755 %{buildroot}/%{_defaultdocdir}/%{name}
|
|
# copy src from build to buildroot
|
|
mv *SUSE %{buildroot}/%{_defaultdocdir}/%{name}
|
|
mv LEGALNOTICE %{buildroot}/%{_defaultdocdir}/%{name}
|
|
mv LICENSE %{buildroot}/%{_defaultdocdir}/%{name}
|
|
mv "misc/How to install Matomo.html" %{buildroot}/%{_defaultdocdir}/%{name}
|
|
mv *md %{buildroot}/%{_defaultdocdir}/%{name}
|
|
cp -dR * %{buildroot}/%{ap_serverroot}/%{name}
|
|
# install matomo.conf to apache conf.d
|
|
install -D -m0640 %{SOURCE2} %{buildroot}/%{ap_sysconfdir}/conf.d/%{name}.conf
|
|
# install logrotate
|
|
install -D -m0644 %{SOURCE3} %{buildroot}/%{_sysconfdir}/logrotate.d/%{name}
|
|
# move config to etc/matomo and make symlink
|
|
mv %{buildroot}/%{ap_serverroot}/%{name}/config/* \
|
|
%{buildroot}/%{_sysconfdir}/%{name}
|
|
rm -d %{buildroot}/%{ap_serverroot}/%{name}/config
|
|
ln -s %{_sysconfdir}/%{name} %{buildroot}/%{ap_serverroot}/%{name}/config
|
|
# install cronscript and systemd-timer
|
|
install -d -m 0755 %{buildroot}/%{_sysconfdir}/cron.d
|
|
install -d -m 0755 %{buildroot}/var/log/%{name}
|
|
install -D -m 0644 %{SOURCE10} %{buildroot}/%{_sysconfdir}/cron.d/%{name}-archive
|
|
install -D -m 0644 %{SOURCE11} %{buildroot}%{_unitdir}/%{name}-archive.service
|
|
install -D -m 0644 %{SOURCE12} %{buildroot}%{_unitdir}/%{name}-archive.timer
|
|
sed -i -e 's|@ap_serverroot@|%{ap_serverroot}|g' %{buildroot}%{_sysconfdir}/cron.d/%{name}-archive
|
|
sed -i -e 's|@ap_serverroot@|%{ap_serverroot}|g' %{buildroot}%{_unitdir}/%{name}-archive.service
|
|
# install changes for mariadb
|
|
install -D -m0644 %{SOURCE13} %{buildroot}/%{_sysconfdir}/my.cnf.d/%{name}.my.cnf
|
|
|
|
%fdupes %{buildroot}/%{_prefix}
|
|
%fdupes %{buildroot}/srv
|
|
|
|
%pre
|
|
%service_add_pre matomo-archive.timer matomo-archive.service
|
|
|
|
%post
|
|
# BSC#1154324
|
|
# # # chown -R %{ap_usr}:%{ap_grp} %{ap_serverroot}/%{name}
|
|
%service_add_post matomo-archive.timer matomo-archive.service apache2.service
|
|
# Update matomo if this is an upgrade $1 == 2
|
|
echo "matomo: Update matomo:core..."
|
|
if [ $1 -gt 1 ]; then
|
|
su wwwrun -s /bin/sh -c "%{_bindir}/php %{ap_serverroot}/%{name}/console config:set 'Tracker.record_statistics="0"'" || :
|
|
su wwwrun -s /bin/sh -c "%{_bindir}/php %{ap_serverroot}/%{name}/console config:set 'General.maintenance_mode="1"'" || :
|
|
su wwwrun -s /bin/sh -c "%{_bindir}/php %{ap_serverroot}/%{name}/console core:update --yes" || :
|
|
su wwwrun -s /bin/sh -c "%{_bindir}/php %{ap_serverroot}/%{name}/console config:set 'General.maintenance_mode="0"'" || :
|
|
su wwwrun -s /bin/sh -c "%{_bindir}/php %{ap_serverroot}/%{name}/console config:set 'Tracker.record_statistics="1"'" || :
|
|
:
|
|
fi
|
|
|
|
%preun
|
|
%service_del_preun matomo-archive.timer matomo-archive.service
|
|
|
|
%postun
|
|
%service_del_postun matomo-archive.timer matomo-archive.service apache2.service
|
|
|
|
%files
|
|
%defattr(-,root,root,-)
|
|
#%%doc README.SUSE CHANGELOG.md CONTRIBUTING.md LEGALNOTICE README.md SECURITY.md
|
|
%dir %{_defaultdocdir}/%{name}
|
|
%{_defaultdocdir}/%{name}/*
|
|
%config(noreplace) %{ap_sysconfdir}/conf.d/%{name}.conf
|
|
%config(noreplace) %{_sysconfdir}/logrotate.d/%{name}
|
|
%config(noreplace) %{_sysconfdir}/cron.d/%{name}-archive
|
|
%config(noreplace) %{_sysconfdir}/my.cnf.d/%{name}.my.cnf
|
|
%{_unitdir}/%{name}-archive.service
|
|
%{_unitdir}/%{name}-archive.timer
|
|
%dir %attr(0750,%{ap_usr},%{ap_grp}) %{_sysconfdir}/%{name}
|
|
%dir %attr(0750,%{ap_usr},%{ap_grp}) %{_sysconfdir}/%{name}/environment
|
|
%attr(0640,%{ap_usr},%{ap_grp}) %{_sysconfdir}/%{name}/*.php
|
|
%attr(0640,%{ap_usr},%{ap_grp}) %{_sysconfdir}/%{name}/environment/*.php
|
|
%defattr(644,root,root,755)
|
|
%dir %{ap_serverroot}/%{name}
|
|
%dir %attr(0750,%{ap_usr},%{ap_grp}) %{ap_serverroot}/%{name}/js
|
|
%dir %attr(0750,%{ap_usr},%{ap_grp}) %{ap_serverroot}/%{name}/misc
|
|
%dir %attr(0750,%{ap_usr},%{ap_grp}) %{ap_serverroot}/%{name}/plugins
|
|
%dir %attr(0750,%{ap_usr},%{ap_grp}) %{ap_serverroot}/%{name}/tmp
|
|
%dir %attr(0750,%{ap_usr},%{ap_grp}) /var/log/%{name}
|
|
%config(noreplace) %attr(600,%{ap_usr},%{ap_grp}) %{_sysconfdir}/%{name}/*php
|
|
%{_sysconfdir}/%{name}/environment/*php
|
|
%attr(0644,%{ap_usr},%{ap_grp}) %{ap_serverroot}/%{name}/matomo.js
|
|
%attr(0644,%{ap_usr},%{ap_grp}) %{ap_serverroot}/%{name}/piwik.js
|
|
%attr(0644,%{ap_usr},%{ap_grp}) %{ap_serverroot}/%{name}/js/piwik.min.js
|
|
%attr(0770,%{ap_usr},%{ap_grp}) %{ap_serverroot}/%{name}/console
|
|
%attr(0770,%{ap_usr},%{ap_grp}) %{ap_serverroot}/%{name}/misc/cron/archive.sh
|
|
%attr(0770,%{ap_usr},%{ap_grp}) %{ap_serverroot}/%{name}/misc/log-analytics/import_logs.py
|
|
%attr(0770,%{ap_usr},%{ap_grp}) %{ap_serverroot}/%{name}/misc/composer/clean-xhprof.sh
|
|
%attr(0770,%{ap_usr},%{ap_grp}) %{ap_serverroot}/%{name}/misc/composer/build-xhprof.sh
|
|
%attr(0770,%{ap_usr},%{ap_grp}) %{ap_serverroot}/%{name}/vendor/leafo/lessphp/package.sh
|
|
%attr(0770,%{ap_usr},%{ap_grp}) %{ap_serverroot}/%{name}/vendor/leafo/lessphp/lessify
|
|
%attr(0770,%{ap_usr},%{ap_grp}) %{ap_serverroot}/%{name}/vendor/leafo/lessphp/plessc
|
|
%attr(0770,%{ap_usr},%{ap_grp}) %{ap_serverroot}/%{name}/vendor/pear/archive_tar/sync-php4
|
|
%attr(0770,%{ap_usr},%{ap_grp}) %{ap_serverroot}/%{name}/vendor/szymach/c-pchart/coverage.sh
|
|
%attr(0770,%{ap_usr},%{ap_grp}) %{ap_serverroot}/%{name}/vendor/tecnickcom/tcpdf/tools/tcpdf_addfont.php
|
|
%{ap_serverroot}/%{name}/*
|
|
|
|
%changelog
|