aboutsummaryrefslogtreecommitdiff
path: root/subsonic-installer-debian/src/DEBIAN/postinst
diff options
context:
space:
mode:
Diffstat (limited to 'subsonic-installer-debian/src/DEBIAN/postinst')
-rw-r--r--subsonic-installer-debian/src/DEBIAN/postinst16
1 files changed, 16 insertions, 0 deletions
diff --git a/subsonic-installer-debian/src/DEBIAN/postinst b/subsonic-installer-debian/src/DEBIAN/postinst
new file mode 100644
index 00000000..da88dd9e
--- /dev/null
+++ b/subsonic-installer-debian/src/DEBIAN/postinst
@@ -0,0 +1,16 @@
+#! /bin/sh
+
+set -e
+
+ln -sf /usr/share/subsonic/subsonic.sh /usr/bin/subsonic
+
+chmod 750 /var/subsonic
+
+# Clear jetty cache.
+rm -rf /var/subsonic/jetty
+
+# Configure Subsonic service.
+update-rc.d subsonic defaults 99
+
+# Start Subsonic service.
+invoke-rc.d subsonic start