snapclient: always restart service

This commit is contained in:
awiouy 2018-03-18 10:38:15 +01:00
parent 484c478fe5
commit f3bd3fab9e
5 changed files with 12 additions and 5 deletions

View File

@ -1,2 +1,7 @@
101
- Always restart service
- Improve latency setting
- Keep daemon state
100
- Initial addon

View File

@ -18,7 +18,7 @@
PKG_NAME="snapclient"
PKG_VERSION="0.13.0"
PKG_REV="100"
PKG_REV="101"
PKG_ARCH="any"
PKG_LICENSE="GPLv3"
PKG_DEPENDS_TARGET="toolchain snapcast"

View File

@ -43,9 +43,11 @@ esac
[ -n "$sc_h" ] && sc_H="--hostID $sc_h"
[ -n "$sc_s" ] && sc_S="--soundcard $sc_s"
HOME="$ADDON_HOME" \
nice -n "$sc_n" \
snapclient \
--daemon "$sc_n" \
$sc_H \
--latency "$sc_l" \
--port "$sc_p" \
$sc_S
$sc_S \
> /dev/null

View File

@ -6,7 +6,7 @@
<setting label="30003" type="text" id="sc_h" default=""/>
<setting label="30004" type="number" id="sc_p" default="1704"/>
<setting label="30005" type="slider" id="sc_n" default="-3" range="-20,1,19" option="int"/>
<setting label="30006" type="slider" id="sc_l" default="0" range="0,1,100" option="int"/>
<setting label="30006" type="number" id="sc_l" default="0"/>
</category>
<category label="30007">
<setting label="30008" type="bool" id="sc_k" default="false"/>

View File

@ -4,8 +4,8 @@ After=kodi.service network-online.target sound.target
Requires=kodi.service network-online.target sound.target
[Service]
Type=forking
ExecStart=/bin/sh /storage/.kodi/addons/service.snapclient/bin/snapclient.start
Restart=always
[Install]
WantedBy=kodi.target