From 9da3f878a2cd127a1beeeae97889d1d691125e89 Mon Sep 17 00:00:00 2001 From: Javier Sánchez Parra Date: Thu, 7 May 2020 11:34:18 +0200 Subject: #981 Add systemd unit file The ogAdmServer needs to be started after MySQL, because it queries the DB at the beginning to obtain the schedules. This commit adds a systemd unit file that force OpenGnsys service to start after MySQL service --- admin/Sources/Services/opengnsys.service | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 admin/Sources/Services/opengnsys.service (limited to 'admin/Sources') diff --git a/admin/Sources/Services/opengnsys.service b/admin/Sources/Services/opengnsys.service new file mode 100644 index 00000000..89b8c492 --- /dev/null +++ b/admin/Sources/Services/opengnsys.service @@ -0,0 +1,25 @@ +# OpenGnsys systemd service file + +[Unit] +Documentation=https://opengnsys.es/trac/wiki/En%3ADocumentacionUsuario +SourcePath=/etc/init.d/opengnsys +Description=LSB: OpenGnsys system services +Before=multi-user.target +Before=graphical.target +Requires=mysql.service +After=mysql.service + +[Install] +WantedBy=multi-user.target + +[Service] +Type=forking +Restart=no +TimeoutSec=5min +IgnoreSIGPIPE=no +KillMode=process +GuessMainPID=no +RemainAfterExit=yes +SuccessExitStatus=5 6 +ExecStart=/etc/init.d/opengnsys start +ExecStop=/etc/init.d/opengnsys stop -- cgit v1.2.3-18-g5258