]> git.ipfire.org Git - people/arne_f/ipfire-3.x.git/blob - cronie/cronie.nm
kernel: update to 4.12.10
[people/arne_f/ipfire-3.x.git] / cronie / cronie.nm
1 ###############################################################################
2 # IPFire.org - An Open Source Firewall Solution #
3 # Copyright (C) - IPFire Development Team <info@ipfire.org> #
4 ###############################################################################
5
6 name = cronie
7 version = 1.5.1
8 release = 2
9
10 groups = System/Environment/Base
11 url = https://github.com/cronie-crond/cronie
12 license = MIT and BSD and ISC and GPLv2
13 summary = Cron daemon for executing programs at set times
14
15 description
16 Cronie contains the standard UNIX daemon crond that runs specified programs at
17 scheduled times and related tools. It is a fork of the
18 original vixie-cron and has security and configuration enhancements like
19 the ability to use pam and SELinux.
20 end
21
22 source_dl = https://github.com/cronie-crond/cronie/releases/download/%{thisapp}/
23
24 build
25 requires
26 bison
27 libcap-devel
28 libedit-devel
29 pam-devel
30 readline-devel
31 systemd-units
32 texinfo
33 end
34
35 configure_options += \
36 --with-pam \
37 --with-inotify \
38 --enable-anacron \
39 --enable-pie \
40 --enable-relro
41
42 test
43 # Cronie does not provide any kind of testsuite.
44 end
45
46 install_cmds
47 mkdir -pv %{BUILDROOT}%{localstatedir}/spool/{ana,}cron
48
49 mkdir -pv %{BUILDROOT}%{sysconfdir}/cron.d
50 touch %{BUILDROOT}%{sysconfdir}/cron.deny
51
52 # Install anacron
53 install -m 644 contrib/anacrontab %{BUILDROOT}%{sysconfdir}/anacrontab
54
55 mkdir -pv %{BUILDROOT}%{sysconfdir}/cron.hourly
56 install -c -m 755 contrib/0anacron %{BUILDROOT}%{sysconfdir}/cron.hourly/0anacron
57 for i in daily weekly monthly; do
58 touch %{BUILDROOT}%{localstatedir}/spool/anacron/cron.${i}
59 done
60
61 install -c -m 755 contrib/0hourly %{BUILDROOT}%{sysconfdir}/cron.d/0hourly
62 end
63 end
64
65 packages
66 package %{name}
67 requires
68 dailyjobs
69 end
70
71 # Just search for new unit files that were just installed.
72 script postin
73 systemctl daemon-reload >/dev/null 2>&1 || :
74
75 # Enable cronie on startup.
76 systemctl enable cronie.service >/dev/null 2>&1 || :
77 end
78
79 # Disable the service that is to be removed and stop it if it is still running.
80 script preun
81 systemctl --no-reload disable cronie.service >/dev/null 2>&1 || :
82 systemctl stop cronie.service >/dev/null 2>&1 || :
83 end
84
85 # Just tell systemd that unitfiles have been removed.
86 script postun
87 systemctl daemon-reload >/dev/null 2>&1 || :
88 end
89
90 # Try to restart the service if it is running.
91 script postup
92 systemctl daemon-reload >/dev/null 2>&1 || :
93 systemctl try-restart cronie.service >/dev/null 2>&1 || :
94 end
95 end
96
97 package anacron
98 summary = Utility for running regular jobs.
99 description
100 Anacron is part of cronie that is used for running jobs with regular
101 periodicity which do not have exact time of day of execution.
102
103 The default settings of anacron execute the daily, weekly, and monthly
104 jobs, but anacron allows setting arbitrary periodicity of jobs.
105
106 Using anacron allows running the periodic jobs even if the system is often
107 powered off and it also allows randomizing the time of the job execution
108 for better utilization of resources shared among multiple systems.
109 end
110 groups = System/Base Base
111
112 provides
113 dailyjobs
114 end
115
116 requires
117 cronie = %{thisver}
118 crontabs
119 end
120
121 files
122 %{sbindir}/anacron
123 %{sysconfdir}/cron.hourly/0anacron
124 %{sysconfdir}/anacrontab
125 %{localstatedir}/spool/anacron
126 %{mandir}/man*/anacron*
127 end
128
129 configfiles
130 %{sysconfdir}/anacrontab
131 end
132
133 datafiles
134 %{localstatedir}/spool/anacron/*
135 end
136 end
137
138 package %{name}-debuginfo
139 template DEBUGINFO
140 end
141 end