Skip to content

Commit 3d5fd85

Browse files
committed
add check line for download of plex on update
1 parent 097b6c5 commit 3d5fd85

2 files changed

Lines changed: 4 additions & 2 deletions

File tree

root/etc/cont-init.d/30-plex-update

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,14 +67,15 @@ fi
6767

6868
last=130
6969
if [[ "$VERSION" == "" ]]; then
70-
echo "ERROR: No version found, running installed version $INSTALLED"
70+
echo "VERSION variable not set, current installed version $INSTALLED"
7171
elif [[ "$VERSION" != "$INSTALLED" ]]; then
7272
echo "Upgrading from version: $INSTALLED to version: $VERSION"
7373
while [[ $last -ne "0" ]]; do
7474
rm -f /tmp/plexmediaserver_*.deb
7575
wget -P /tmp "https://downloads.plex.tv/plex-media-server/$VERSION/plexmediaserver_${VERSION}_amd64.deb"
7676
last=$?
7777
done
78+
[[ ! -e /tmp/plexmediaserver_"${VERSION}"_amd64.deb ]] && exit 0
7879
apt-get remove --purge -y plexmediaserver
7980
dpkg -i /tmp/plexmediaserver_"${VERSION}"_amd64.deb
8081
else

root/etc/cont-init.d/40-chown-files

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,8 @@ if [ ! -d "/config/Library" ]; then
66
fi
77

88
if [ ! -f "/config/Library/linuxserver-chown.lock" ]; then
9-
find /config/Library ! \( -user abc -a -group root \) -print0 | xargs -0 chown abc:root
9+
find /config/Library ! \( -user abc -a -group abc \) -print0 | xargs -0 chown abc:abc
1010
touch /config/Library/linuxserver-chown.lock
11+
chown abc:abc /config/Library/linuxserver-chown.lock
1112
fi
1213

0 commit comments

Comments
 (0)