--- /dev/null
+[Unit]
+Description=Evergreen Reporter
+After=opensrf.service
+BindsTo=opensrf.service
+
+[Service]
+User=opensrf
+Group=opensrf
+Type=forking
+Environment=PATH=/openils/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
+#ExecStartPre=/bin/sleep 2
+
+# TODO: -c template variable
+ExecStart=/openils/bin/clark-kent.pl --daemon
+ExecStopPost=/bin/rm /tmp/reporter-LOCK
+
+#[Install]
+#WantedBy=multi-user.target
--- /dev/null
+# TODO: 'Before' and 'After' reflect a single-server setup.
+# Make these configurable for cases where certain services
+# (e.g. memcache) are not run on the same machine.
+
+[Unit]
+Description=Open Service Request Framework
+After=ejabberd.service memcached.service
+Before=apache2.service apache2-websockets.service
+Requries=memcached.service
+BindsTo=ejabberd.service
+
+[Service]
+User=opensrf
+Group=opensrf
+Type=oneshot
+RemainAfterExit=yes
+Environment=PATH=/openils/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
+Environment=LD_LIBRARY_PATH=/openils/lib:/usr/local/lib:/usr/local/lib/dbd:$LD_LIBRARY_PATH
+#ExecStartPre=/bin/sleep 5
+ExecStart=/openils/bin/osrf_control -l --start-all
+#ExecStartPost=/bin/sleep 10
+#ExecStartPost=-/bin/systemctl restart apache2.service
+#ExecStartPost=-/bin/systemctl restart apache2-websockets.service
+ExecStop=/openils/bin/osrf_control -l --stop-all
+
+#[Install]
+#WantedBy=multi-user.target
+#Alias=opensrf.service
+
+++ /dev/null
-# TODO: 'Before' and 'After' reflect a single-server setup.
-# Make these configurable for cases where certain services
-# (e.g. memcache) are not run on the same machine.
-
-[Unit]
-Description=Open Service Request Framework
-After=ejabberd.service memcached.service
-Before=apache2.service apache2-websockets.service
-Requries=memcached.service
-BindsTo=ejabberd.service
-
-[Service]
-User=opensrf
-Group=opensrf
-Type=oneshot
-RemainAfterExit=yes
-Environment=PATH=/openils/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin
-Environment=LD_LIBRARY_PATH=/openils/lib:/usr/local/lib:/usr/local/lib/dbd:$LD_LIBRARY_PATH
-#ExecStartPre=/bin/sleep 5
-ExecStart=/openils/bin/osrf_control -l --start-all
-#ExecStartPost=/bin/sleep 10
-#ExecStartPost=-/bin/systemctl restart apache2.service
-#ExecStartPost=-/bin/systemctl restart apache2-websockets.service
-ExecStop=/openils/bin/osrf_control -l --stop-all
-
-#[Install]
-#WantedBy=multi-user.target
-#Alias=opensrf.service
-
- name: Install OpenSRF Service File
become: true
template:
- src: extras/service_files/opensrf.service.j2
+ src: extras/service-files/opensrf.service.j2
dest: /lib/systemd/system/opensrf.service
owner: root
group: root
mode: 0644
+- name: Install Evergreen Reporter Service File
+ become: true
+ template:
+ src: extras/service-files/evergreen-reporter.service.j2
+ dest: /lib/systemd/system/evergreen-reporter.service
+ owner: root
+ group: root
+ mode: 0644
- name: Reload Systemd Configs
become: true
shell: systemctl daemon-reload