From e570944fdbe637ae1d3410c1d403e853686a1689 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Elan=20Ruusam=C3=A4e?= Date: Wed, 6 Jan 2010 15:58:49 +0000 Subject: [PATCH] - up to r4022, switching to uid/gid http Changed files: eventum-mail-download.cron -> 1.7 eventum-mail-queue.cron -> 1.8 eventum-monitor.cron -> 1.8 eventum-reminder.cron -> 1.7 eventum.spec -> 1.311 --- eventum-mail-download.cron | 2 +- eventum-mail-queue.cron | 2 +- eventum-monitor.cron | 2 +- eventum-reminder.cron | 2 +- eventum.spec | 42 +++++++++++++++++++++++--------------- 5 files changed, 29 insertions(+), 21 deletions(-) diff --git a/eventum-mail-download.cron b/eventum-mail-download.cron index 3794c2c..bf70e73 100644 --- a/eventum-mail-download.cron +++ b/eventum-mail-download.cron @@ -11,4 +11,4 @@ MAILTO=root # # Administration >>> Manage Email Accounts -#0 * * * * eventum /usr/share/eventum/download_emails.php username_here mail.domain.com INBOX +#0 * * * * http /usr/share/eventum/download_emails.php username_here mail.domain.com INBOX diff --git a/eventum-mail-queue.cron b/eventum-mail-queue.cron index 291942d..7e687d7 100644 --- a/eventum-mail-queue.cron +++ b/eventum-mail-queue.cron @@ -2,7 +2,7 @@ # bounce messages back to root MAILTO=root -* * * * * eventum /usr/share/eventum/process_mail_queue.php +* * * * * http /usr/share/eventum/process_mail_queue.php # The above line will run the mail queue script every minute. To setup # the SMTP server that Eventum should use to send these queued emails, diff --git a/eventum-monitor.cron b/eventum-monitor.cron index db1b4aa..6e65228 100644 --- a/eventum-monitor.cron +++ b/eventum-monitor.cron @@ -2,4 +2,4 @@ # bounce messages back to root MAILTO=root -*/10 * * * * eventum /usr/share/eventum/monitor.php +*/10 * * * * http /usr/share/eventum/monitor.php diff --git a/eventum-reminder.cron b/eventum-reminder.cron index 7528fa5..040ab15 100644 --- a/eventum-reminder.cron +++ b/eventum-reminder.cron @@ -2,7 +2,7 @@ # bounce messages back to root MAILTO=root -*/10 * * * * eventum /usr/share/eventum/check_reminders.php +*/10 * * * * http /usr/share/eventum/check_reminders.php # It is recommended that you run the reminder cron job every 10 minutes, # so it won't flood you with alerts too often, but it would still be diff --git a/eventum.spec b/eventum.spec index 9ea07bf..4aa48b2 100644 --- a/eventum.spec +++ b/eventum.spec @@ -10,8 +10,8 @@ %bcond_without order # with experimental order patch #define snap 20060921 -%define rev r4018 -%define rel 2.49 +%define rev r4022 +%define rel 2.54 #define _rc RC3 %define php_min_version 5.1.2 @@ -28,7 +28,7 @@ Group: Applications/WWW #Source0: http://mysql.easynet.be/Downloads/eventum/%{name}-%{version}.tar.gz # bzr branch lp:eventum eventum && cd eventum && make dist Source0: %{name}-%{version}-dev-%{rev}.tar.gz -# Source0-md5: 74cc4307c0641c2fbe7e543e994cfbe0 +# Source0-md5: 660e9e1e8cd45e848fc84f7d02361fb8 Source1: %{name}-apache.conf Source2: %{name}-mail-queue.cron Source3: %{name}-mail-download.cron @@ -57,8 +57,6 @@ BuildRequires: gettext-devel BuildRequires: rpm-php-pearprov >= 4.0.2-98 BuildRequires: rpmbuild(macros) >= 1.461 BuildRequires: sed >= 4.0 -Requires(triggerpostun): /usr/bin/php -Requires(triggerpostun): sed >= 4.0 Requires: %{name}-base = %{version}-%{release} Requires: Smarty >= 2.6.10-4 Requires: php-common >= 4:%{php_min_version} @@ -367,7 +365,6 @@ Summary: Eventum IRC Notification Bot Summary(pl.UTF-8): IRC-owy bot powiadamiający dla Eventum Group: Applications/WWW Requires(post,preun): /sbin/chkconfig -Requires(triggerpostun): sed >= 4.0 Requires: %{name} = %{version}-%{release} Requires: php(sockets) Requires: php-pear-Net_SmartIRC @@ -660,21 +657,32 @@ fi %triggerun -- lighttpd %webapp_unregister lighttpd %{_webapp} +%triggerpostun -- %{name} < 2.2-2.54 +set -x +chgrp http %{_webappdir}/config.php +chgrp http %{_webappdir}/private_key.php +chgrp http %{_webappdir}/setup.php +chgrp http /var/log/%{name}/* +# update crontab user +for a in /etc/cron.d/eventum-*; do + awk '!/#/ && NR > 6 && $6 =="eventum" {sub("eventum", "http", $6)}{print}' $a > $a.rpmtmp && cat $a.rpmtmp > $a + rm -f $a.rpmtmp +done + %files -f %{name}.lang %defattr(644,root,root,755) -%doc ChangeLog FAQ INSTALL README UPGRADE CONTRIB %doc docs/* htdocs/setup/schema.sql mysql-permissions.sql %attr(751,root,root) %dir %{_webappdir} %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_webappdir}/apache.conf %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_webappdir}/httpd.conf %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_webappdir}/lighttpd.conf -%attr(640,root,eventum) %config(noreplace) %verify(not md5 mtime size) %{_webappdir}/config.php -%attr(640,root,eventum) %config(noreplace) %verify(not md5 mtime size) %{_webappdir}/private_key.php -%attr(660,root,eventum) %config(noreplace) %verify(not md5 mtime size) %{_webappdir}/setup.php +%attr(640,root,http) %config(noreplace) %verify(not md5 mtime size) %{_webappdir}/config.php +%attr(640,root,http) %config(noreplace) %verify(not md5 mtime size) %{_webappdir}/private_key.php +%attr(660,root,http) %config(noreplace) %verify(not md5 mtime size) %{_webappdir}/setup.php %attr(640,root,http) %config(noreplace) %verify(not md5 mtime size) %{_webappdir}/htpasswd -%dir %attr(731,root,eventum) /var/log/%{name} -%attr(620,root,eventum) %ghost /var/log/%{name}/* +%dir %attr(731,root,http) /var/log/%{name} +%attr(620,root,http) %ghost /var/log/%{name}/* %dir %attr(750,root,root) /var/log/archive/%{name} %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/logrotate.d/%{name} @@ -707,8 +715,8 @@ fi %{_appdir}/lib/jpgraph %exclude %{_appdir}/lib/eventum/class.monitor.php -%dir %attr(730,root,eventum) /var/run/%{name} -%dir %attr(730,root,eventum) /var/cache/%{name} +%dir %attr(730,root,http) /var/run/%{name} +%dir %attr(730,root,http) /var/cache/%{name} %files base %defattr(644,root,root,755) @@ -717,9 +725,9 @@ fi %dir %{_appdir} %dir /var/lib/%{name} # saved mail copies -%attr(770,root,eventum) %dir /var/lib/%{name}/routed_emails -%attr(770,root,eventum) %dir /var/lib/%{name}/routed_drafts -%attr(770,root,eventum) %dir /var/lib/%{name}/routed_notes +%attr(770,root,http) %dir /var/lib/%{name}/routed_emails +%attr(770,root,http) %dir /var/lib/%{name}/routed_drafts +%attr(770,root,http) %dir /var/lib/%{name}/routed_notes %files setup %defattr(644,root,root,755) -- 2.44.0