diff --git a/nextcloud/11.0/Dockerfile b/nextcloud/11.0/Dockerfile index 8809451..354caf2 100644 --- a/nextcloud/11.0/Dockerfile +++ b/nextcloud/11.0/Dockerfile @@ -14,8 +14,7 @@ ENV UID=991 GID=991 \ DB_TYPE=sqlite3 \ DOMAIN=localhost -RUN echo "@testing https://nl.alpinelinux.org/alpine/edge/community" >> /etc/apk/repositories \ - && echo "@testing https://nl.alpinelinux.org/alpine/edge/testing" >> /etc/apk/repositories \ +RUN echo "@testing https://nl.alpinelinux.org/alpine/edge/testing" >> /etc/apk/repositories \ && BUILD_DEPS=" \ gnupg \ tar \ diff --git a/nextcloud/daily/Dockerfile b/nextcloud/daily/Dockerfile index 6eae175..b0ba0ff 100644 --- a/nextcloud/daily/Dockerfile +++ b/nextcloud/daily/Dockerfile @@ -75,6 +75,7 @@ RUN echo "@testing https://nl.alpinelinux.org/alpine/edge/testing" >> /etc/apk/r && echo "extension=iconv.so" > /etc/php7.1/conf.d/00_iconv.ini \ && echo "extension=smbclient.so" > /etc/php7.1/conf.d/00_smbclient.ini \ && echo "extension=redis.so" > /etc/php7.1/conf.d/redis.ini \ + && sed -i 's|;session.save_path = "/tmp"|session.save_path = "/data/session"|g' /etc/php7.1/php.ini \ && mkdir /nextcloud \ && wget -q https://download.nextcloud.com/server/daily/latest.tar.bz2 \ && tar xjf latest.tar.bz2 --strip 1 -C /nextcloud \ diff --git a/nextcloud/daily/run.sh b/nextcloud/daily/run.sh index 451103d..ac968ab 100644 --- a/nextcloud/daily/run.sh +++ b/nextcloud/daily/run.sh @@ -12,6 +12,11 @@ ln -sf /apps2 /nextcloud &>/dev/null mv nextcloud fix && mv fix nextcloud # fix strange bug +# Create folder for php sessions if not exists +if [ ! -d /data/session ]; then + mkdir -p /data/session; +fi + echo "Updating permissions..." for dir in /nextcloud /data /config /apps2 /etc/nginx /etc/php7.1 /var/log /var/lib/nginx /tmp /etc/s6.d; do if $(find $dir ! -user $UID -o ! -group $GID|egrep '.' -q); then diff --git a/nextcloud/daily/setup.sh b/nextcloud/daily/setup.sh index a481867..7d2dd4f 100755 --- a/nextcloud/daily/setup.sh +++ b/nextcloud/daily/setup.sh @@ -98,6 +98,7 @@ echo ";"; EOF sed -i "s/localhost/$DOMAIN/g" /config/config.php + chown -R $UID:$GID /config /data # Enable/disable apps. Note that this must be done after the ownCloud setup. # The firstrunwizard gave Josh all sorts of problems, so disabling that.