Subject: Re: dcron-4.4 systemd service
From: Jim Pryor <[email-masked]>
To: Miklos Vajna <[email-masked]>

On Sat, Jan 15, 2011 at 02:17:43AM +0100, Miklos Vajna wrote:
> Hi,                                                                                                                                       
>                                                                                                                                           
> I'm attaching a patch adding crond.service for systemd, based on                                                                          
> crond.rc. I'm submitting it as a patch, as one of systemd's great idea                                                                    
> is to let upstream ship service files, so the "every distro packager                                                                      
> writes his own rc script" issue won't happen again. :)                                                                                    
>                                                                                                                                           
> Thanks,                                                                                                                                   
>                                                                                                                                           
> Miklos                                                                                                                                    

Thanks Miklos, I'll fold this into next release, which I hope to be able
to get together soon.

From 86d87f86fce00f1534987547233dfcea07cbd9ab Mon Sep 17 00:00:00 2001
From: Miklos Vajna <[email-masked]>
Date: Sat, 15 Jan 2011 02:01:46 +0100
Subject: [PATCH] Add systemd unit file

---
 README              |    4 ++++
 extra/crond.service |   10 ++++++++++
 2 files changed, 14 insertions(+), 0 deletions(-)
 create mode 100644 extra/crond.service

diff --git a/README b/README
index 3b8b9d3..a720009 100644
--- a/README
+++ b/README
@@ -144,6 +144,10 @@ crond.rc
 :	This is an example rc script to start and stop crond. It could be placed in
 /etc/rc.d or /etc/init.d in suitable systems.
 
+crond.service
+:	This is an example sysvinit service to start and stop crond. It
+could be placed in /lib/systemd/system in suitable systems.
+
 run-cron
 :	This simple shell script is a bare-bones alternative to Debian's run-parts.
 
diff --git a/extra/crond.service b/extra/crond.service
new file mode 100644
index 0000000..536404d
--- /dev/null
+++ b/extra/crond.service
@@ -0,0 +1,10 @@
+[Unit]
+Description=Cron Daemon
+After=syslog.target
+
+[Service]
+ExecStart=/usr/sbin/crond -S -l info
+Type=forking
+
+[Install]
+WantedBy=multi-user.target
-- 
1.7.3.4