mirror of
https://github.com/mail-in-a-box/mailinabox.git
synced 2024-11-22 02:17:26 +00:00
fixes comments by @JoshData
This commit is contained in:
parent
ee244386ed
commit
8b2fed1a2a
@ -13,21 +13,20 @@ apt_install \
|
|||||||
apt-get purge -qq -y owncloud*
|
apt-get purge -qq -y owncloud*
|
||||||
|
|
||||||
# Install ownCloud from source
|
# Install ownCloud from source
|
||||||
echo installing ownCloud...
|
# Check if ownCloud dir exist, and check if version matches 7.0.1 (if it does, upgrade)
|
||||||
rm -f /tmp/owncloud.zip
|
owncloud_ver=7.0.2
|
||||||
wget -qO /tmp/owncloud.zip https://download.owncloud.org/community/owncloud-latest.zip
|
|
||||||
|
|
||||||
if [ ! -d /usr/local/lib/owncloud ]; then
|
if [ ! -d /usr/local/lib/owncloud/ ] \
|
||||||
# fresh install
|
|| ! grep -q $owncloud_ver /usr/local/lib/owncloud/version.php; then
|
||||||
unzip -q /tmp/owncloud.zip -d /usr/local/lib
|
|
||||||
else
|
echo installing ownCloud...
|
||||||
# upgrade existing install
|
rm -f /tmp/owncloud.zip
|
||||||
unzip -u -o -q /tmp/owncloud.zip -d /usr/local/lib
|
wget -qO /tmp/owncloud.zip https://download.owncloud.org/community/owncloud-$owncloud_ver.zip
|
||||||
hide_output php /usr/local/lib/owncloud/occ upgrade
|
unzip -u -o -q /tmp/owncloud.zip -d /usr/local/lib #either extracts new or replaces current files
|
||||||
|
hide_output php /usr/local/lib/owncloud/occ upgrade #if OC is up-to-date it wont matter
|
||||||
|
rm -f /tmp/owncloud.zip
|
||||||
fi
|
fi
|
||||||
|
|
||||||
rm -f /tmp/owncloud.zip
|
|
||||||
|
|
||||||
# Setup ownCloud if the ownCloud database does not yet exist. Running setup when
|
# Setup ownCloud if the ownCloud database does not yet exist. Running setup when
|
||||||
# the database does exist wipes the database and user data.
|
# the database does exist wipes the database and user data.
|
||||||
if [ ! -f $STORAGE_ROOT/owncloud/owncloud.db ]; then
|
if [ ! -f $STORAGE_ROOT/owncloud/owncloud.db ]; then
|
||||||
|
Loading…
Reference in New Issue
Block a user