diff --git a/CHANGELOG.md b/CHANGELOG.md index ffa05015..46087860 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -20,7 +20,7 @@ System: * Backups can now be turned off, or stored in Amazon S3, through new control panel options. * Munin was not working on machines confused about their hostname. * SSL certificate checks were failing on OVH/OpenVZ servers due to missing /dev/stdin. -* ownCloud updated to version 8.1.1. +* ownCloud updated to version 8.1.1, its memcached caching enabled. * When upgrading, network checks like blocked port 25 are now skipped. * Tweaks to the intrusion detection rules for IMAP. * Improve the sort order of the domains in the status checks. diff --git a/setup/owncloud.sh b/setup/owncloud.sh index e5892186..3c21a056 100755 --- a/setup/owncloud.sh +++ b/setup/owncloud.sh @@ -10,7 +10,7 @@ source /etc/mailinabox.conf # load global vars apt_install \ dbconfig-common \ php5-cli php5-sqlite php5-gd php5-imap php5-curl php-pear php-apc curl libapr1 libtool libcurl4-openssl-dev php-xml-parser \ - php5 php5-dev php5-gd php5-fpm memcached php5-memcache unzip + php5 php5-dev php5-gd php5-fpm memcached php5-memcached unzip apt-get purge -qq -y owncloud* @@ -102,6 +102,7 @@ if [ ! -f $STORAGE_ROOT/owncloud/owncloud.db ]; then 'arguments'=>array('{localhost:993/imap/ssl/novalidate-cert}') ) ), + 'memcache.local' => '\\OC\\Memcache\\Memcached', "memcached_servers" => array ( array('localhost', 11211), ), @@ -148,6 +149,21 @@ EOF (cd /usr/local/lib/owncloud; sudo -u www-data php /usr/local/lib/owncloud/index.php;) fi +# Update existing configuration files with changed settings that weren't included in +# previous versions of Mail-in-a-Box. Use PHP to read the settings file, modify it, +# and write out the new settings array. +CONFIG_TEMP=$(/bin/mktemp) +php < $CONFIG_TEMP && mv $CONFIG_TEMP $STORAGE_ROOT/owncloud/config.php; + +EOF +chown www-data.www-data $STORAGE_ROOT/owncloud/config.php + # Enable/disable apps. Note that this must be done after the ownCloud setup. # The firstrunwizard gave Josh all sorts of problems, so disabling that. # user_external is what allows ownCloud to use IMAP for login. The contacts diff --git a/setup/system.sh b/setup/system.sh index 84f6bd89..2d929f9d 100755 --- a/setup/system.sh +++ b/setup/system.sh @@ -48,7 +48,7 @@ apt_get_quiet upgrade # * netcat-openbsd: `nc` command line networking tool # * git: we install some things directly from github # * sudo: allows privileged users to execute commands as root without being root -# * coreutils: includes `nproc` tool to report number of processors +# * coreutils: includes `nproc` tool to report number of processors, mktemp # * bc: allows us to do math to compute sane defaults apt_install python3 python3-dev python3-pip \