Instantly share code, notes, and snippets.

Embed
What would you like to do?
BubbleUPnP Server Systemd Unit
[Unit]
Description=BubbleUPnP Server
Requires=network-online.target
After=network-online.target
[Service]
Type=simple
Environment=DEFAULTFILE=/etc/default/bubbleupnpserver
Restart=on-failure
ExecStartPre=/usr/share/bubbleupnpserver/startService.sh
ExecStart=/usr/share/bubbleupnpserver/launch.sh ${OPTS}
[Install]
WantedBy=multi-user.target
#!/bin/bash
if [ -f "$DEFAULTFILE" ]; then
. "$DEFAULTFILE"
else
USER=root
DATADIR=/root/.bubbleupnpserver
HTTP_PORT=58050
HTTPS_PORT=58051
fi
# Make sure daemon is started with system locale
if [ -r /etc/default/locale ]; then
. /etc/default/locale
export LANG
fi
OPTS="-dataDir ${DATADIR} -httpPort ${HTTP_PORT} -httpsPort ${HTTPS_PORT} -nologstdout"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment