From 894d4b74fa9942fcf27f3715df832b2e048ba0d9 Mon Sep 17 00:00:00 2001 From: sparklyballs Date: Wed, 11 Jan 2017 19:51:37 +0000 Subject: [PATCH] use PLEX_MEDIA_SERVER_INFO_DEVICE=docker to identify to pms using a docker image, fix quotes on variable, shellcheck --- Dockerfile | 4 ++-- root/etc/cont-init.d/40-chown-files | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Dockerfile b/Dockerfile index c5b7d96..ae57867 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,14 +1,14 @@ FROM lsiobase/xenial MAINTAINER Stian Larsen, sparklyballs -# package version -ENV PLEX_INSTALL="https://plex.tv/downloads/latest/1?channel=8&build=linux-ubuntu-x86_64&distro=ubuntu" # global environment settings ENV DEBIAN_FRONTEND="noninteractive" \ PLEX_DOWNLOAD="https://downloads.plex.tv/plex-media-server" \ +PLEX_INSTALL="https://plex.tv/downloads/latest/1?channel=8&build=linux-ubuntu-x86_64&distro=ubuntu" \ PLEX_MEDIA_SERVER_APPLICATION_SUPPORT_DIR="/config/Library/Application Support" \ PLEX_MEDIA_SERVER_HOME="/usr/lib/plexmediaserver" \ +PLEX_MEDIA_SERVER_INFO_DEVICE=docker \ PLEX_MEDIA_SERVER_MAX_PLUGIN_PROCS="6" # install packages diff --git a/root/etc/cont-init.d/40-chown-files b/root/etc/cont-init.d/40-chown-files index 062a022..61fcf71 100644 --- a/root/etc/cont-init.d/40-chown-files +++ b/root/etc/cont-init.d/40-chown-files @@ -4,7 +4,7 @@ if [ ! -d "${PLEX_MEDIA_SERVER_APPLICATION_SUPPORT_DIR}" ]; then mkdir -p "${PLEX_MEDIA_SERVER_APPLICATION_SUPPORT_DIR}" chown abc:abc "${PLEX_MEDIA_SERVER_APPLICATION_SUPPORT_DIR}" -elif [ ! "$(stat -c %u ${PLEX_MEDIA_SERVER_APPLICATION_SUPPORT_DIR})" = "$PUID" ]; then +elif [ ! "$(stat -c %u "${PLEX_MEDIA_SERVER_APPLICATION_SUPPORT_DIR}")" = "$PUID" ]; then echo "Change in ownership detected, please be patient while we chown existing files" echo "This could take some time" chown abc:abc -R \