mirror of
https://github.com/mail-in-a-box/mailinabox.git
synced 2024-11-22 02:17:26 +00:00
Merge branch 'owncloud' of github.com:jkaberg/mailinabox into owncloud
Conflicts: conf/nginx.conf setup/zpush.sh
This commit is contained in:
commit
05cc63b5d5
@ -61,13 +61,10 @@ server {
|
|||||||
location ~ ^(/cloud)(/.+\.php)(/.*)?$ {
|
location ~ ^(/cloud)(/.+\.php)(/.*)?$ {
|
||||||
# note: ~ has precendence over a regular location block
|
# note: ~ has precendence over a regular location block
|
||||||
include fastcgi_params;
|
include fastcgi_params;
|
||||||
fastcgi_param PHP_VALUE "upload_max_filesize = 16G";
|
|
||||||
fastcgi_param PHP_VALUE "post_max_size = 16G";
|
|
||||||
fastcgi_param PHP_VALUE "output_buffering = 16384";
|
|
||||||
fastcgi_param PHP_VALUE "memory_limit = 512M";
|
|
||||||
fastcgi_param SCRIPT_FILENAME /usr/local/lib/owncloud/$2;
|
fastcgi_param SCRIPT_FILENAME /usr/local/lib/owncloud/$2;
|
||||||
fastcgi_param SCRIPT_NAME $1$2;
|
fastcgi_param SCRIPT_NAME $1$2;
|
||||||
fastcgi_param PATH_INFO $3;
|
fastcgi_param PATH_INFO $3;
|
||||||
|
fastcgi_param MOD_X_ACCEL_REDIRECT_ENABLED on;
|
||||||
fastcgi_pass php-fpm;
|
fastcgi_pass php-fpm;
|
||||||
error_page 403 /cloud/core/templates/403.php;
|
error_page 403 /cloud/core/templates/403.php;
|
||||||
error_page 404 /cloud/core/templates/404.php;
|
error_page 404 /cloud/core/templates/404.php;
|
||||||
|
@ -7,14 +7,14 @@ source /etc/mailinabox.conf # load global vars
|
|||||||
apt_install \
|
apt_install \
|
||||||
dbconfig-common \
|
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-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 sqlite
|
php5 php5-dev php5-gd php5-fpm memcached php5-memcache unzip
|
||||||
|
|
||||||
apt-get purge -qq -y owncloud*
|
apt-get purge -qq -y owncloud*
|
||||||
|
|
||||||
# Install ownCloud from source if it is not already present
|
# Install ownCloud from source if it is not already present
|
||||||
# TODO: Check version?
|
# TODO: Check version?
|
||||||
if [ ! -d /usr/local/lib/owncloud ]; then
|
if [ ! -d /usr/local/lib/owncloud ]; then
|
||||||
echo Installing ownCloud...
|
echo installing ownCloud...
|
||||||
rm -f /tmp/owncloud.zip
|
rm -f /tmp/owncloud.zip
|
||||||
wget -qO /tmp/owncloud.zip https://download.owncloud.org/community/owncloud-7.0.1.zip
|
wget -qO /tmp/owncloud.zip https://download.owncloud.org/community/owncloud-7.0.1.zip
|
||||||
unzip -q /tmp/owncloud.zip -d /usr/local/lib
|
unzip -q /tmp/owncloud.zip -d /usr/local/lib
|
||||||
@ -72,6 +72,13 @@ EOF
|
|||||||
mkdir -p $STORAGE_ROOT/owncloud
|
mkdir -p $STORAGE_ROOT/owncloud
|
||||||
chown -R www-data.www-data $STORAGE_ROOT/owncloud /usr/local/lib/owncloud
|
chown -R www-data.www-data $STORAGE_ROOT/owncloud /usr/local/lib/owncloud
|
||||||
|
|
||||||
|
# Set PHP FPM values to support large file uploads
|
||||||
|
tools/editconf.py /etc/php5/fpm/php.ini \
|
||||||
|
upload_max_filesize=16G \
|
||||||
|
post_max_size=16G \
|
||||||
|
output_buffering=16384 \
|
||||||
|
memory_limit=512M
|
||||||
|
|
||||||
# Download and install the mail app
|
# Download and install the mail app
|
||||||
# TODO: enable mail app in ownCloud config, not exposed afaik?
|
# TODO: enable mail app in ownCloud config, not exposed afaik?
|
||||||
if [ ! -d /usr/local/lib/owncloud/apps/mail ]; then
|
if [ ! -d /usr/local/lib/owncloud/apps/mail ]; then
|
||||||
@ -95,5 +102,9 @@ chmod -R 777 /usr/local/lib/owncloud/apps/mail/vendor/ezyang/htmlpurifier/librar
|
|||||||
hide_output php /usr/local/lib/owncloud/console.php app:enable user_external
|
hide_output php /usr/local/lib/owncloud/console.php app:enable user_external
|
||||||
hide_output php /usr/local/lib/owncloud/console.php app:enable mail
|
hide_output php /usr/local/lib/owncloud/console.php app:enable mail
|
||||||
|
|
||||||
|
# Enable apps.
|
||||||
|
hide_output php /usr/local/lib/owncloud/console.php app:enable user_external
|
||||||
|
hide_output php /usr/local/lib/owncloud/console.php app:enable mail
|
||||||
|
|
||||||
php5enmod imap
|
php5enmod imap
|
||||||
restart_service php5-fpm
|
restart_service php5-fpm
|
||||||
|
@ -14,7 +14,7 @@ source /etc/mailinabox.conf # load global vars
|
|||||||
# Prereqs.
|
# Prereqs.
|
||||||
|
|
||||||
apt_install \
|
apt_install \
|
||||||
php-soap php5-imap libawl-php
|
php-soap php5-imap libawl-php php5-xsl
|
||||||
|
|
||||||
php5enmod imap
|
php5enmod imap
|
||||||
|
|
||||||
@ -29,7 +29,7 @@ fi
|
|||||||
if [ $needs_update == 1 ]; then
|
if [ $needs_update == 1 ]; then
|
||||||
rm -rf /usr/local/lib/z-push
|
rm -rf /usr/local/lib/z-push
|
||||||
rm -f /tmp/zpush.zip
|
rm -f /tmp/zpush.zip
|
||||||
echo Installing z-push \(fmbiete fork\)...
|
echo installing z-push \(fmbiete fork\)...
|
||||||
wget -qO /tmp/zpush.zip https://github.com/fmbiete/Z-Push-contrib/archive/master.zip
|
wget -qO /tmp/zpush.zip https://github.com/fmbiete/Z-Push-contrib/archive/master.zip
|
||||||
unzip -q /tmp/zpush.zip -d /usr/local/lib/
|
unzip -q /tmp/zpush.zip -d /usr/local/lib/
|
||||||
mv /usr/local/lib/Z-Push-contrib-master /usr/local/lib/z-push
|
mv /usr/local/lib/Z-Push-contrib-master /usr/local/lib/z-push
|
||||||
|
17
tools/update_mail_app.sh
Normal file
17
tools/update_mail_app.sh
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
# Simple script to update the mail app in ownCloud, not needed once it reaches beta+
|
||||||
|
|
||||||
|
echo "installing mail app..."
|
||||||
|
rm -f /tmp/owncloud_mail.zip
|
||||||
|
wget -qO /tmp/owncloud_mail.zip https://github.com/owncloud/mail/archive/master.zip
|
||||||
|
unzip /tmp/owncloud_mail.zip -d /usr/local/lib/owncloud/apps
|
||||||
|
mv /usr/local/lib/owncloud/apps/mail-master /usr/local/lib/owncloud/apps/mail
|
||||||
|
rm -f /tmp/owncloud.zip
|
||||||
|
|
||||||
|
echo "installing php composer and mail app dependencies..."
|
||||||
|
curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/lib/owncloud/apps/mail
|
||||||
|
php /usr/local/lib/owncloud/apps/mail/composer.phar install --working-dir=/usr/local/lib/owncloud/apps/mail
|
||||||
|
chmod -R 777 /usr/local/lib/owncloud/apps/mail/vendor/ezyang/htmlpurifier/library/HTMLPurifier/DefinitionCache/Serializer
|
||||||
|
|
||||||
|
echo "DONE! :-)"
|
Loading…
Reference in New Issue
Block a user