0
0
Fork 0
mirror of https://github.com/nextcloud/docker.git synced 2025-03-15 19:05:09 +01:00
This commit is contained in:
naramski 2018-12-14 09:52:46 +01:00
parent 31d7dedda9
commit 71a8f0ef64
14 changed files with 158 additions and 0 deletions

View file

@ -127,6 +127,20 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
fi fi
fi fi
if [ -n "${NEXTCLOUD_OVERWRITEHOST+x}" ]; then
echo "setting overwritehost…"
run_as "php /var/www/html/occ config:system:set overwritehost --value=$NEXTCLOUD_OVERWRITEHOST"
fi
if [ -n "${NEXTCLOUD_OVERWRITEPROTOCOL+x}" ]; then
echo "setting overwriteprotocol…"
run_as "php /var/www/html/occ config:system:set overwriteprotocol --value=$NEXTCLOUD_OVERWRITEPROTOCOL"
fi
if [ -n "${NEXTCLOUD_OVERWRITEWEBROOT+x}" ]; then
echo "setting overwritewebroot…"
run_as "php /var/www/html/occ config:system:set overwritewebroot --value=$NEXTCLOUD_OVERWRITEWEBROOT"
fi
fi fi
exec "$@" exec "$@"

View file

@ -127,6 +127,20 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
fi fi
fi fi
if [ -n "${NEXTCLOUD_OVERWRITEHOST+x}" ]; then
echo "setting overwritehost…"
run_as "php /var/www/html/occ config:system:set overwritehost --value=$NEXTCLOUD_OVERWRITEHOST"
fi
if [ -n "${NEXTCLOUD_OVERWRITEPROTOCOL+x}" ]; then
echo "setting overwriteprotocol…"
run_as "php /var/www/html/occ config:system:set overwriteprotocol --value=$NEXTCLOUD_OVERWRITEPROTOCOL"
fi
if [ -n "${NEXTCLOUD_OVERWRITEWEBROOT+x}" ]; then
echo "setting overwritewebroot…"
run_as "php /var/www/html/occ config:system:set overwritewebroot --value=$NEXTCLOUD_OVERWRITEWEBROOT"
fi
fi fi
exec "$@" exec "$@"

View file

@ -127,6 +127,20 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
fi fi
fi fi
if [ -n "${NEXTCLOUD_OVERWRITEHOST+x}" ]; then
echo "setting overwritehost…"
run_as "php /var/www/html/occ config:system:set overwritehost --value=$NEXTCLOUD_OVERWRITEHOST"
fi
if [ -n "${NEXTCLOUD_OVERWRITEPROTOCOL+x}" ]; then
echo "setting overwriteprotocol…"
run_as "php /var/www/html/occ config:system:set overwriteprotocol --value=$NEXTCLOUD_OVERWRITEPROTOCOL"
fi
if [ -n "${NEXTCLOUD_OVERWRITEWEBROOT+x}" ]; then
echo "setting overwritewebroot…"
run_as "php /var/www/html/occ config:system:set overwritewebroot --value=$NEXTCLOUD_OVERWRITEWEBROOT"
fi
fi fi
exec "$@" exec "$@"

View file

@ -127,6 +127,20 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
fi fi
fi fi
if [ -n "${NEXTCLOUD_OVERWRITEHOST+x}" ]; then
echo "setting overwritehost…"
run_as "php /var/www/html/occ config:system:set overwritehost --value=$NEXTCLOUD_OVERWRITEHOST"
fi
if [ -n "${NEXTCLOUD_OVERWRITEPROTOCOL+x}" ]; then
echo "setting overwriteprotocol…"
run_as "php /var/www/html/occ config:system:set overwriteprotocol --value=$NEXTCLOUD_OVERWRITEPROTOCOL"
fi
if [ -n "${NEXTCLOUD_OVERWRITEWEBROOT+x}" ]; then
echo "setting overwritewebroot…"
run_as "php /var/www/html/occ config:system:set overwritewebroot --value=$NEXTCLOUD_OVERWRITEWEBROOT"
fi
fi fi
exec "$@" exec "$@"

View file

@ -127,6 +127,20 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
fi fi
fi fi
if [ -n "${NEXTCLOUD_OVERWRITEHOST+x}" ]; then
echo "setting overwritehost…"
run_as "php /var/www/html/occ config:system:set overwritehost --value=$NEXTCLOUD_OVERWRITEHOST"
fi
if [ -n "${NEXTCLOUD_OVERWRITEPROTOCOL+x}" ]; then
echo "setting overwriteprotocol…"
run_as "php /var/www/html/occ config:system:set overwriteprotocol --value=$NEXTCLOUD_OVERWRITEPROTOCOL"
fi
if [ -n "${NEXTCLOUD_OVERWRITEWEBROOT+x}" ]; then
echo "setting overwritewebroot…"
run_as "php /var/www/html/occ config:system:set overwritewebroot --value=$NEXTCLOUD_OVERWRITEWEBROOT"
fi
fi fi
exec "$@" exec "$@"

View file

@ -127,6 +127,20 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
fi fi
fi fi
if [ -n "${NEXTCLOUD_OVERWRITEHOST+x}" ]; then
echo "setting overwritehost…"
run_as "php /var/www/html/occ config:system:set overwritehost --value=$NEXTCLOUD_OVERWRITEHOST"
fi
if [ -n "${NEXTCLOUD_OVERWRITEPROTOCOL+x}" ]; then
echo "setting overwriteprotocol…"
run_as "php /var/www/html/occ config:system:set overwriteprotocol --value=$NEXTCLOUD_OVERWRITEPROTOCOL"
fi
if [ -n "${NEXTCLOUD_OVERWRITEWEBROOT+x}" ]; then
echo "setting overwritewebroot…"
run_as "php /var/www/html/occ config:system:set overwritewebroot --value=$NEXTCLOUD_OVERWRITEWEBROOT"
fi
fi fi
exec "$@" exec "$@"

View file

@ -109,7 +109,11 @@ RUN a2enmod rewrite remoteip ;\
} > /etc/apache2/conf-available/remoteip.conf;\ } > /etc/apache2/conf-available/remoteip.conf;\
a2enconf remoteip a2enconf remoteip
<<<<<<< HEAD:15.0/apache/Dockerfile
ENV NEXTCLOUD_VERSION 15.0.0 ENV NEXTCLOUD_VERSION 15.0.0
=======
ENV NEXTCLOUD_VERSION 12.0.13
>>>>>>> Add two parameters when Nextcloud is behind a proxy:12.0/apache/Dockerfile
RUN set -ex; \ RUN set -ex; \
fetchDeps=" \ fetchDeps=" \

View file

@ -127,6 +127,20 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
fi fi
fi fi
if [ -n "${NEXTCLOUD_OVERWRITEHOST+x}" ]; then
echo "setting overwritehost…"
run_as "php /var/www/html/occ config:system:set overwritehost --value=$NEXTCLOUD_OVERWRITEHOST"
fi
if [ -n "${NEXTCLOUD_OVERWRITEPROTOCOL+x}" ]; then
echo "setting overwriteprotocol…"
run_as "php /var/www/html/occ config:system:set overwriteprotocol --value=$NEXTCLOUD_OVERWRITEPROTOCOL"
fi
if [ -n "${NEXTCLOUD_OVERWRITEWEBROOT+x}" ]; then
echo "setting overwritewebroot…"
run_as "php /var/www/html/occ config:system:set overwritewebroot --value=$NEXTCLOUD_OVERWRITEWEBROOT"
fi
fi fi
exec "$@" exec "$@"

View file

@ -90,7 +90,11 @@ RUN { \
VOLUME /var/www/html VOLUME /var/www/html
<<<<<<< HEAD:15.0/fpm-alpine/Dockerfile
ENV NEXTCLOUD_VERSION 15.0.0 ENV NEXTCLOUD_VERSION 15.0.0
=======
ENV NEXTCLOUD_VERSION 12.0.13
>>>>>>> Add two parameters when Nextcloud is behind a proxy:12.0/fpm-alpine/Dockerfile
RUN set -ex; \ RUN set -ex; \
apk add --no-cache --virtual .fetch-deps \ apk add --no-cache --virtual .fetch-deps \

View file

@ -127,6 +127,20 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
fi fi
fi fi
if [ -n "${NEXTCLOUD_OVERWRITEHOST+x}" ]; then
echo "setting overwritehost…"
run_as "php /var/www/html/occ config:system:set overwritehost --value=$NEXTCLOUD_OVERWRITEHOST"
fi
if [ -n "${NEXTCLOUD_OVERWRITEPROTOCOL+x}" ]; then
echo "setting overwriteprotocol…"
run_as "php /var/www/html/occ config:system:set overwriteprotocol --value=$NEXTCLOUD_OVERWRITEPROTOCOL"
fi
if [ -n "${NEXTCLOUD_OVERWRITEWEBROOT+x}" ]; then
echo "setting overwritewebroot…"
run_as "php /var/www/html/occ config:system:set overwritewebroot --value=$NEXTCLOUD_OVERWRITEWEBROOT"
fi
fi fi
exec "$@" exec "$@"

View file

@ -101,7 +101,11 @@ RUN { \
VOLUME /var/www/html VOLUME /var/www/html
<<<<<<< HEAD:15.0/fpm/Dockerfile
ENV NEXTCLOUD_VERSION 15.0.0 ENV NEXTCLOUD_VERSION 15.0.0
=======
ENV NEXTCLOUD_VERSION 12.0.13
>>>>>>> Add two parameters when Nextcloud is behind a proxy:12.0/fpm/Dockerfile
RUN set -ex; \ RUN set -ex; \
fetchDeps=" \ fetchDeps=" \

View file

@ -127,6 +127,20 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
fi fi
fi fi
if [ -n "${NEXTCLOUD_OVERWRITEHOST+x}" ]; then
echo "setting overwritehost…"
run_as "php /var/www/html/occ config:system:set overwritehost --value=$NEXTCLOUD_OVERWRITEHOST"
fi
if [ -n "${NEXTCLOUD_OVERWRITEPROTOCOL+x}" ]; then
echo "setting overwriteprotocol…"
run_as "php /var/www/html/occ config:system:set overwriteprotocol --value=$NEXTCLOUD_OVERWRITEPROTOCOL"
fi
if [ -n "${NEXTCLOUD_OVERWRITEWEBROOT+x}" ]; then
echo "setting overwritewebroot…"
run_as "php /var/www/html/occ config:system:set overwritewebroot --value=$NEXTCLOUD_OVERWRITEWEBROOT"
fi
fi fi
exec "$@" exec "$@"

View file

@ -130,7 +130,13 @@ The install and update script is only triggered when a default command is used (
- `NEXTCLOUD_UPDATE` (default: _0_) - `NEXTCLOUD_UPDATE` (default: _0_)
If Nextcloud fails to automatically detect the hostname, protocol or webroot you can use the overwrite parameters inside the config/config.php.
- `NEXTCLOUD_OVERWRITEHOST` The overwritehost parameter is used to set the hostname of the proxy. You can also specify a port.
- `NEXTCLOUD_OVERWRITEPROTOCOL` The overwriteprotocol parameter is used to set the protocol of the proxy. You can choose between the two options http and https.
- `NEXTCLOUD_OVERWRITEWEBROOT` The overwritewebroot parameter is used to set the absolute web path of the proxy to the Nextcloud folder.
These parameters are available in v14.0+
# Running this image with docker-compose # Running this image with docker-compose
The easiest way to get a fully featured and functional setup is using a `docker-compose` file. There are too many different possibilities to setup your system, so here are only some examples what you have to look for. The easiest way to get a fully featured and functional setup is using a `docker-compose` file. There are too many different possibilities to setup your system, so here are only some examples what you have to look for.

View file

@ -127,6 +127,20 @@ if expr "$1" : "apache" 1>/dev/null || [ "$1" = "php-fpm" ] || [ "${NEXTCLOUD_UP
fi fi
fi fi
if [ -n "${NEXTCLOUD_OVERWRITEHOST+x}" ]; then
echo "setting overwritehost…"
run_as "php /var/www/html/occ config:system:set overwritehost --value=$NEXTCLOUD_OVERWRITEHOST"
fi
if [ -n "${NEXTCLOUD_OVERWRITEPROTOCOL+x}" ]; then
echo "setting overwriteprotocol…"
run_as "php /var/www/html/occ config:system:set overwriteprotocol --value=$NEXTCLOUD_OVERWRITEPROTOCOL"
fi
if [ -n "${NEXTCLOUD_OVERWRITEWEBROOT+x}" ]; then
echo "setting overwritewebroot…"
run_as "php /var/www/html/occ config:system:set overwritewebroot --value=$NEXTCLOUD_OVERWRITEWEBROOT"
fi
fi fi
exec "$@" exec "$@"