mirror of
https://github.com/mail-in-a-box/mailinabox.git
synced 2024-12-25 07:47:05 +00:00
update nextcloud to 24
This commit is contained in:
parent
bf4ec5697b
commit
314955a648
@ -21,8 +21,8 @@ echo "Installing Nextcloud (contacts/calendar)..."
|
|||||||
# we automatically install intermediate versions as needed.
|
# we automatically install intermediate versions as needed.
|
||||||
# * The hash is the SHA1 hash of the ZIP package, which you can find by just running this script and
|
# * The hash is the SHA1 hash of the ZIP package, which you can find by just running this script and
|
||||||
# copying it from the error message when it doesn't match what is below.
|
# copying it from the error message when it doesn't match what is below.
|
||||||
nextcloud_ver=23.0.2
|
nextcloud_ver=24.0.0
|
||||||
nextcloud_hash=645cba42cab57029ebe29fb93906f58f7abea5f8
|
nextcloud_hash=f072f5863a15cefe577b47f72bb3e41d2a339335
|
||||||
|
|
||||||
# Nextcloud apps
|
# Nextcloud apps
|
||||||
# --------------
|
# --------------
|
||||||
@ -34,11 +34,11 @@ nextcloud_hash=645cba42cab57029ebe29fb93906f58f7abea5f8
|
|||||||
# * The hash is the SHA1 hash of the ZIP package, which you can find by just running this script and
|
# * The hash is the SHA1 hash of the ZIP package, which you can find by just running this script and
|
||||||
# copying it from the error message when it doesn't match what is below.
|
# copying it from the error message when it doesn't match what is below.
|
||||||
contacts_ver=4.0.8
|
contacts_ver=4.0.8
|
||||||
contacts_hash=9f368bb2be98c5555b7118648f4cc9fa51e8cb30
|
contacts_hash=fc626ec02732da13a4c600baae64ab40557afdca
|
||||||
calendar_ver=3.0.6
|
calendar_ver=3.0.6
|
||||||
calendar_hash=ca49bb1ce23f20e10911e39055fd59d7f7a84c30
|
calendar_hash=e40d919b4b7988b46671a78cb32a43d8c7cba332
|
||||||
user_external_ver=3.0.0
|
user_external_ver=3.0.0
|
||||||
user_external_hash=6e5afe7f36f398f864bfdce9cad72200e70322aa
|
user_external_hash=9e7aaf7288032bd463c480bc368ff91869122950
|
||||||
|
|
||||||
# Clear prior packages and install dependencies from apt.
|
# Clear prior packages and install dependencies from apt.
|
||||||
|
|
||||||
@ -100,12 +100,9 @@ InstallNextcloud() {
|
|||||||
# Starting with Nextcloud 15, the app user_external is no longer included in Nextcloud core,
|
# Starting with Nextcloud 15, the app user_external is no longer included in Nextcloud core,
|
||||||
# we will install from their github repository.
|
# we will install from their github repository.
|
||||||
if [ -n "$version_user_external" ]; then
|
if [ -n "$version_user_external" ]; then
|
||||||
wget_verify https://github.com/nextcloud/user_external/releases/download/v$version_user_external/user_external-$version_user_external.tar.gz $hash_user_external /tmp/user_external.tgz
|
wget_verify https://github.com/nextcloud/user_external/archive/refs/tags/v$version_user_external.tar.gz $hash_user_external /tmp/user_external.tgz
|
||||||
tar -xf /tmp/user_external.tgz -C /usr/local/lib/owncloud/apps/
|
tar -xf /tmp/user_external.tgz -C /usr/local/lib/owncloud/apps/
|
||||||
rm /tmp/user_external.tgz
|
rm /tmp/user_external.tgz
|
||||||
|
|
||||||
# (Temporary?) workaround to get user_external working with Nextcloud 23 (see https://github.com/nextcloud/user_external/issues/186)
|
|
||||||
# sed -i "s/nextcloud min-version=\"21\" max-version=\"22\"/nextcloud min-version=\"21\" max-version=\"23\"/g" /usr/local/lib/owncloud/apps/user_external/appinfo/info.xml
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Fix weird permissions.
|
# Fix weird permissions.
|
||||||
@ -232,6 +229,10 @@ if [ ! -d /usr/local/lib/owncloud/ ] || [[ ! ${CURRENT_NEXTCLOUD_VER} =~ ^$nextc
|
|||||||
InstallNextcloud 22.2.3 58d2d897ba22a057aa03d29c762c5306211fefd2 4.0.7 8ab31d205408e4f12067d8a4daa3595d46b513e3 3.0.4 6fb1e998d307c53245faf1c37a96eb982bbee8ba 2.1.0 6e5afe7f36f398f864bfdce9cad72200e70322aa
|
InstallNextcloud 22.2.3 58d2d897ba22a057aa03d29c762c5306211fefd2 4.0.7 8ab31d205408e4f12067d8a4daa3595d46b513e3 3.0.4 6fb1e998d307c53245faf1c37a96eb982bbee8ba 2.1.0 6e5afe7f36f398f864bfdce9cad72200e70322aa
|
||||||
CURRENT_NEXTCLOUD_VER="22.2.3"
|
CURRENT_NEXTCLOUD_VER="22.2.3"
|
||||||
fi
|
fi
|
||||||
|
if [[ ${CURRENT_NEXTCLOUD_VER} =~ ^22 ]]; then
|
||||||
|
InstallNextcloud 23.0.2 645cba42cab57029ebe29fb93906f58f7abea5f8 4.0.8 9f368bb2be98c5555b7118648f4cc9fa51e8cb30 3.0.6 ca49bb1ce23f20e10911e39055fd59d7f7a84c30 2.1.0 6e5afe7f36f398f864bfdce9cad72200e70322aa
|
||||||
|
CURRENT_NEXTCLOUD_VER="23.0.2"
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
InstallNextcloud $nextcloud_ver $nextcloud_hash $contacts_ver $contacts_hash $calendar_ver $calendar_hash $user_external_ver $user_external_hash
|
InstallNextcloud $nextcloud_ver $nextcloud_hash $contacts_ver $contacts_hash $calendar_ver $calendar_hash $user_external_ver $user_external_hash
|
||||||
@ -325,7 +326,7 @@ php <<EOF > $CONFIG_TEMP && mv $CONFIG_TEMP $STORAGE_ROOT/owncloud/config.php;
|
|||||||
<?php
|
<?php
|
||||||
include("$STORAGE_ROOT/owncloud/config.php");
|
include("$STORAGE_ROOT/owncloud/config.php");
|
||||||
|
|
||||||
\$CONFIG['config_is_read_only'] = true; # should prevent warnings from occ tool but doesn't
|
\$CONFIG['config_is_read_only'] = false; # should prevent warnings from occ tool but doesn't
|
||||||
|
|
||||||
\$CONFIG['trusted_domains'] = array('$PRIMARY_HOSTNAME');
|
\$CONFIG['trusted_domains'] = array('$PRIMARY_HOSTNAME');
|
||||||
|
|
||||||
@ -338,7 +339,7 @@ include("$STORAGE_ROOT/owncloud/config.php");
|
|||||||
|
|
||||||
\$CONFIG['mail_domain'] = '$PRIMARY_HOSTNAME';
|
\$CONFIG['mail_domain'] = '$PRIMARY_HOSTNAME';
|
||||||
|
|
||||||
\$CONFIG['user_backends'] = array(array('class' => 'OC_User_IMAP','arguments' => array('127.0.0.1', 143, null),),);
|
\$CONFIG['user_backends'] = array(array('class' => '\OCA\UserExternal\IMAP','arguments' => array('127.0.0.1', 143, null),),);
|
||||||
|
|
||||||
echo "<?php\n\\\$CONFIG = ";
|
echo "<?php\n\\\$CONFIG = ";
|
||||||
var_export(\$CONFIG);
|
var_export(\$CONFIG);
|
||||||
@ -347,6 +348,8 @@ echo ";";
|
|||||||
EOF
|
EOF
|
||||||
chown www-data.www-data $STORAGE_ROOT/owncloud/config.php
|
chown www-data.www-data $STORAGE_ROOT/owncloud/config.php
|
||||||
|
|
||||||
|
# Need to change config if external_user is version 3.0.0 or higher, above works only on new installs
|
||||||
|
|
||||||
# Enable/disable apps. Note that this must be done after the Nextcloud setup.
|
# Enable/disable apps. Note that this must be done after the Nextcloud setup.
|
||||||
# The firstrunwizard gave Josh all sorts of problems, so disabling that.
|
# The firstrunwizard gave Josh all sorts of problems, so disabling that.
|
||||||
# user_external is what allows Nextcloud to use IMAP for login. The contacts
|
# user_external is what allows Nextcloud to use IMAP for login. The contacts
|
||||||
|
Loading…
Reference in New Issue
Block a user