| 1 | # Do not edit this file, it will be replaced on update |
|---|
| 2 | # If you need to make modifications to this unit file first make a copy in |
|---|
| 3 | # /etc/systemd/system |
|---|
| 4 | |
|---|
| 5 | # This file is part of the packaging of MythTV |
|---|
| 6 | # |
|---|
| 7 | # MythTV is free software; view http://www.mythtv.org |
|---|
| 8 | # for more information. |
|---|
| 9 | # |
|---|
| 10 | # It is sometimes necessary to wait for a capture |
|---|
| 11 | # device to finish (hot)plug initialization before |
|---|
| 12 | # the backend starts. If this is necessary, |
|---|
| 13 | # create a Wants and After entry for all the capture |
|---|
| 14 | # devices that one wishes to wait to be created |
|---|
| 15 | # before the backend starts using the systemd |
|---|
| 16 | # device name mangling names (/dev/some/thing turns |
|---|
| 17 | # into dev-some-thing.device). These normally should |
|---|
| 18 | # be udev persistent filename rules to avoid confusion. |
|---|
| 19 | # See the MythTV wiki for udev persistent filename |
|---|
| 20 | # discussions found at: |
|---|
| 21 | # http://www.mythtv.org/wiki/Device_Filenames_and_udev |
|---|
| 22 | # |
|---|
| 23 | # In order to insure that systemd will create a |
|---|
| 24 | # device unit for the capture device, one must |
|---|
| 25 | # insure that udev will have the tag "systemd" |
|---|
| 26 | # (i.e. add TAG+="systemd" to the udev rule). |
|---|
| 27 | # |
|---|
| 28 | # The MythTV package ships with a default udev |
|---|
| 29 | # rule file located in: /lib/udev/rules.d/99-mythbackend.rules |
|---|
| 30 | |
|---|
| 31 | |
|---|
| 32 | [Unit] |
|---|
| 33 | Description=MythTV backend service |
|---|
| 34 | After=network.target mysqld.service |
|---|
| 35 | # uncomment the following line if you will be using the mythweb plugin. |
|---|
| 36 | #Wants=httpd.service |
|---|
| 37 | |
|---|
| 38 | [Service] |
|---|
| 39 | Type=simple |
|---|
| 40 | Environment=MYTHCONFDIR=/etc/mythtv |
|---|
| 41 | Environment=HOME=/usr/share/mythtv |
|---|
| 42 | User=mythtv |
|---|
| 43 | ExecStart=/usr/bin/mythbackend --logpath /var/log/mythtv/ |
|---|
| 44 | |
|---|
| 45 | [Install] |
|---|
| 46 | WantedBy=multi-user.target |
|---|