add check line for download of plex on update
This commit is contained in:
parent
097b6c57ed
commit
3d5fd85f3c
2 changed files with 4 additions and 2 deletions
|
|
@ -67,7 +67,7 @@ fi
|
||||||
|
|
||||||
last=130
|
last=130
|
||||||
if [[ "$VERSION" == "" ]]; then
|
if [[ "$VERSION" == "" ]]; then
|
||||||
echo "ERROR: No version found, running installed version $INSTALLED"
|
echo "VERSION variable not set, current installed version $INSTALLED"
|
||||||
elif [[ "$VERSION" != "$INSTALLED" ]]; then
|
elif [[ "$VERSION" != "$INSTALLED" ]]; then
|
||||||
echo "Upgrading from version: $INSTALLED to version: $VERSION"
|
echo "Upgrading from version: $INSTALLED to version: $VERSION"
|
||||||
while [[ $last -ne "0" ]]; do
|
while [[ $last -ne "0" ]]; do
|
||||||
|
|
@ -75,6 +75,7 @@ elif [[ "$VERSION" != "$INSTALLED" ]]; then
|
||||||
wget -P /tmp "https://downloads.plex.tv/plex-media-server/$VERSION/plexmediaserver_${VERSION}_amd64.deb"
|
wget -P /tmp "https://downloads.plex.tv/plex-media-server/$VERSION/plexmediaserver_${VERSION}_amd64.deb"
|
||||||
last=$?
|
last=$?
|
||||||
done
|
done
|
||||||
|
[[ ! -e /tmp/plexmediaserver_"${VERSION}"_amd64.deb ]] && exit 0
|
||||||
apt-get remove --purge -y plexmediaserver
|
apt-get remove --purge -y plexmediaserver
|
||||||
dpkg -i /tmp/plexmediaserver_"${VERSION}"_amd64.deb
|
dpkg -i /tmp/plexmediaserver_"${VERSION}"_amd64.deb
|
||||||
else
|
else
|
||||||
|
|
|
||||||
|
|
@ -6,7 +6,8 @@ if [ ! -d "/config/Library" ]; then
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ ! -f "/config/Library/linuxserver-chown.lock" ]; then
|
if [ ! -f "/config/Library/linuxserver-chown.lock" ]; then
|
||||||
find /config/Library ! \( -user abc -a -group root \) -print0 | xargs -0 chown abc:root
|
find /config/Library ! \( -user abc -a -group abc \) -print0 | xargs -0 chown abc:abc
|
||||||
touch /config/Library/linuxserver-chown.lock
|
touch /config/Library/linuxserver-chown.lock
|
||||||
|
chown abc:abc /config/Library/linuxserver-chown.lock
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue