LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (http://www.linuxquestions.org/questions/linux-software-2/)
-   -   Convert init script to systemd file service (http://www.linuxquestions.org/questions/linux-software-2/convert-init-script-to-systemd-file-service-4175432265/)

igor012 10-15-2012 04:21 AM

Convert init script to systemd file service
 
Hello,
On OpenSUSE I am trying to convert one of my init script to a systemd service file.

Here is what I wrote
Code:

[Unit]
Description=myscript
#
#Requires=
#
#After=syslog.target

[Service]
ExecStart=/bin/bash -c "if [ -f /opt/script.py ]; then /usr/bin/python /opt/script.py; fi"
#
#
Type=forking
PIDFile=/var/run/script.pid

[Install]
WantedBy=multi-user.target

When starting it, it fails.

What did I miss ?

Thanks

unSpawn 10-15-2012 10:05 AM

Quote:

Originally Posted by igor012 (Post 4805967)
When starting it, it fails.

Stdout, stderr, debug mode, syslog, any clues? What does it fail on?


All times are GMT -5. The time now is 08:30 PM.