aboutsummaryrefslogtreecommitdiff
path: root/debian/conf
diff options
context:
space:
mode:
authorJoshua M. Boniface <joshua@boniface.me>2020-03-22 16:01:33 -0400
committerJoshua M. Boniface <joshua@boniface.me>2020-03-22 16:01:33 -0400
commit8b620ed26addec0f42e2797e3e4d45fbd68b0f23 (patch)
tree33e4fa49ce16f540867986f2a27f335bd0a36c1d /debian/conf
parent28f7df652015013ff5cedb10971fb69c8e41d2b1 (diff)
Move Debian folder to root of repo
Diffstat (limited to 'debian/conf')
-rw-r--r--debian/conf/jellyfin40
-rw-r--r--debian/conf/jellyfin-sudoers37
-rw-r--r--debian/conf/jellyfin.service.conf7
-rw-r--r--debian/conf/logging.json30
4 files changed, 114 insertions, 0 deletions
diff --git a/debian/conf/jellyfin b/debian/conf/jellyfin
new file mode 100644
index 000000000..c6e595f15
--- /dev/null
+++ b/debian/conf/jellyfin
@@ -0,0 +1,40 @@
+# Jellyfin default configuration options
+# This is a POSIX shell fragment
+
+# Use this file to override the default configurations; add additional
+# options with JELLYFIN_ADD_OPTS.
+
+# Under systemd, use
+# /etc/systemd/system/jellyfin.service.d/jellyfin.service.conf
+# to override the user or this config file's location.
+
+#
+# General options
+#
+
+# Program directories
+JELLYFIN_DATA_DIR="/var/lib/jellyfin"
+JELLYFIN_CONFIG_DIR="/etc/jellyfin"
+JELLYFIN_LOG_DIR="/var/log/jellyfin"
+JELLYFIN_CACHE_DIR="/var/cache/jellyfin"
+
+# Restart script for in-app server control
+JELLYFIN_RESTART_OPT="--restartpath=/usr/lib/jellyfin/restart.sh"
+
+# ffmpeg binary paths, overriding the system values
+JELLYFIN_FFMPEG_OPT="--ffmpeg=/usr/lib/jellyfin-ffmpeg/ffmpeg"
+
+# [OPTIONAL] run Jellyfin as a headless service
+#JELLYFIN_SERVICE_OPT="--service"
+
+# [OPTIONAL] run Jellyfin without the web app
+#JELLYFIN_NOWEBAPP_OPT="--noautorunwebapp"
+
+#
+# SysV init/Upstart options
+#
+
+# Application username
+JELLYFIN_USER="jellyfin"
+# Full application command
+JELLYFIN_ARGS="$JELLYFIN_RESTART_OPT $JELLYFIN_FFMPEG_OPT $JELLYFIN_SERVICE_OPT $JELLFIN_NOWEBAPP_OPT"
diff --git a/debian/conf/jellyfin-sudoers b/debian/conf/jellyfin-sudoers
new file mode 100644
index 000000000..b481ba4ad
--- /dev/null
+++ b/debian/conf/jellyfin-sudoers
@@ -0,0 +1,37 @@
+#Allow jellyfin group to start, stop and restart itself
+Cmnd_Alias RESTARTSERVER_SYSV = /sbin/service jellyfin restart, /usr/sbin/service jellyfin restart
+Cmnd_Alias STARTSERVER_SYSV = /sbin/service jellyfin start, /usr/sbin/service jellyfin start
+Cmnd_Alias STOPSERVER_SYSV = /sbin/service jellyfin stop, /usr/sbin/service jellyfin stop
+Cmnd_Alias RESTARTSERVER_SYSTEMD = /usr/bin/systemctl restart jellyfin, /bin/systemctl restart jellyfin
+Cmnd_Alias STARTSERVER_SYSTEMD = /usr/bin/systemctl start jellyfin, /bin/systemctl start jellyfin
+Cmnd_Alias STOPSERVER_SYSTEMD = /usr/bin/systemctl stop jellyfin, /bin/systemctl stop jellyfin
+Cmnd_Alias RESTARTSERVER_INITD = /etc/init.d/jellyfin restart
+Cmnd_Alias STARTSERVER_INITD = /etc/init.d/jellyfin start
+Cmnd_Alias STOPSERVER_INITD = /etc/init.d/jellyfin stop
+
+
+jellyfin ALL=(ALL) NOPASSWD: RESTARTSERVER_SYSV
+jellyfin ALL=(ALL) NOPASSWD: STARTSERVER_SYSV
+jellyfin ALL=(ALL) NOPASSWD: STOPSERVER_SYSV
+jellyfin ALL=(ALL) NOPASSWD: RESTARTSERVER_SYSTEMD
+jellyfin ALL=(ALL) NOPASSWD: STARTSERVER_SYSTEMD
+jellyfin ALL=(ALL) NOPASSWD: STOPSERVER_SYSTEMD
+jellyfin ALL=(ALL) NOPASSWD: RESTARTSERVER_INITD
+jellyfin ALL=(ALL) NOPASSWD: STARTSERVER_INITD
+jellyfin ALL=(ALL) NOPASSWD: STOPSERVER_INITD
+
+Defaults!RESTARTSERVER_SYSV !requiretty
+Defaults!STARTSERVER_SYSV !requiretty
+Defaults!STOPSERVER_SYSV !requiretty
+Defaults!RESTARTSERVER_SYSTEMD !requiretty
+Defaults!STARTSERVER_SYSTEMD !requiretty
+Defaults!STOPSERVER_SYSTEMD !requiretty
+Defaults!RESTARTSERVER_INITD !requiretty
+Defaults!STARTSERVER_INITD !requiretty
+Defaults!STOPSERVER_INITD !requiretty
+
+#Allow the server to mount iso images
+jellyfin ALL=(ALL) NOPASSWD: /bin/mount
+jellyfin ALL=(ALL) NOPASSWD: /bin/umount
+
+Defaults:jellyfin !requiretty
diff --git a/debian/conf/jellyfin.service.conf b/debian/conf/jellyfin.service.conf
new file mode 100644
index 000000000..1b69dd74e
--- /dev/null
+++ b/debian/conf/jellyfin.service.conf
@@ -0,0 +1,7 @@
+# Jellyfin systemd configuration options
+
+# Use this file to override the user or environment file location.
+
+[Service]
+#User = jellyfin
+#EnvironmentFile = /etc/default/jellyfin
diff --git a/debian/conf/logging.json b/debian/conf/logging.json
new file mode 100644
index 000000000..f32b2089e
--- /dev/null
+++ b/debian/conf/logging.json
@@ -0,0 +1,30 @@
+{
+ "Serilog": {
+ "MinimumLevel": "Information",
+ "WriteTo": [
+ {
+ "Name": "Console",
+ "Args": {
+ "outputTemplate": "[{Timestamp:HH:mm:ss}] [{Level:u3}] {Message:lj}{NewLine}{Exception}"
+ }
+ },
+ {
+ "Name": "Async",
+ "Args": {
+ "configure": [
+ {
+ "Name": "File",
+ "Args": {
+ "path": "%JELLYFIN_LOG_DIR%//jellyfin.log",
+ "fileSizeLimitBytes": 10485700,
+ "rollOnFileSizeLimit": true,
+ "retainedFileCountLimit": 10,
+ "outputTemplate": "[{Timestamp:yyyy-MM-dd HH:mm:ss.fff zzz}] [{Level:u3}] {Message}{NewLine}{Exception}"
+ }
+ }
+ ]
+ }
+ }
+ ]
+ }
+}