Merge pull request #31 from Apocrathia/Apocrathia-patch-1

Added systemd support to AUTOSTART
This commit is contained in:
Henric Andersson 2015-10-27 11:16:06 -07:00
commit d5a592fe38

View file

@ -317,7 +317,12 @@ if [ "${AUTOSTART}" == "yes" ]; then
if [ "${REDHAT}" == "no" ]; then
echo "The AUTOSTART [-s] option may not be needed on your distribution."
fi
service plexmediaserver start
# Check for systemd
if [ -f "/bin/systemctl" ]; then
systemctl start plexmediaserver.service
else
service plexmediaserver start
fi
fi
exit 0