mirror of
https://github.com/nextcloud/nextcloudpi.git
synced 2026-01-10 15:12:01 -03:30
update: check for docker build for fixes
This commit is contained in:
parent
019c2f0da8
commit
261326c594
18
update.sh
18
update.sh
@ -12,13 +12,15 @@ cp etc/library.sh /usr/local/etc/
|
||||
|
||||
source /usr/local/etc/library.sh
|
||||
|
||||
# fix automount, reinstall if its old version
|
||||
AMFILE=/usr/local/etc/nextcloudpi-config.d/nc-automount.sh
|
||||
test -e $AMFILE && { grep -q inotify-tools $AMFILE || rm $AMFILE; }
|
||||
pgrep -x mysqld &>/dev/null && { # skip docker build
|
||||
# fix automount, reinstall if its old version
|
||||
AMFILE=/usr/local/etc/nextcloudpi-config.d/nc-automount.sh
|
||||
test -e $AMFILE && { grep -q inotify-tools $AMFILE || rm $AMFILE; }
|
||||
|
||||
# fix modsecurity, reinstall if its old verion
|
||||
MSFILE=/usr/local/etc/nextcloudpi-config.d/modsecurity.sh
|
||||
test -e $MSFILE && { grep -q "NextCloudPi:" $MSFILE || rm $MSFILE; }
|
||||
# fix modsecurity, reinstall if its old verion
|
||||
MSFILE=/usr/local/etc/nextcloudpi-config.d/modsecurity.sh
|
||||
test -e $MSFILE && { grep -q "NextCloudPi:" $MSFILE || rm $MSFILE; }
|
||||
}
|
||||
|
||||
# copy all files in bin and etc
|
||||
for file in bin/* etc/*; do
|
||||
@ -59,6 +61,8 @@ chmod 770 /var/www/ncp-web
|
||||
|
||||
## BACKWARD FIXES ( for older images )
|
||||
|
||||
pgrep -x mysqld &>/dev/null && { # skip docker build
|
||||
|
||||
# force-fix unattended-upgrades
|
||||
cd /usr/local/etc/nextcloudpi-config.d/ || exit 1
|
||||
activate_script unattended-upgrades.sh
|
||||
@ -148,6 +152,8 @@ test -f /usr/local/etc/ncp-baseimage || echo "untagged" > /usr/local/etc/ncp-bas
|
||||
# remove artifacts
|
||||
rm -f /usr/local/etc/nextcloudpi-config.d/config_.txt
|
||||
|
||||
}
|
||||
|
||||
# License
|
||||
#
|
||||
# This script is free software; you can redistribute it and/or modify it
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user