Browse Source

updates to nextcloud

feature/startup-from-labels
Mar Alegre 4 years ago
parent
commit
d020864805
  1. 13
      nextcloud/Containerfile
  2. 2
      nextcloud/assets/bin/maint
  3. 10
      nextcloud/assets/data/host.config.php

13
nextcloud/Containerfile

@ -6,7 +6,7 @@ FROM localhost/debian
# deploy options # deploy options
# -p (port) and -v (volume) both go host:container # -p (port) and -v (volume) both go host:container
LABEL config_default="\ LABEL config_default="\
--cap-add SYS_ADMIN \ --privileged \
-p 9080:80 \ -p 9080:80 \
-v /srv/vol/nextcloud/files:/vol/files \ -v /srv/vol/nextcloud/files:/vol/files \
-v /srv/vol/nextcloud/data:/vol/data" -v /srv/vol/nextcloud/data:/vol/data"
@ -43,6 +43,11 @@ RUN usermod --uid $FILESUID www-data && \
# copy our custom scripts # copy our custom scripts
COPY assets/bin/ /usr/local/bin/ COPY assets/bin/ /usr/local/bin/
# make sure volume dirs exist, and copy sample data
RUN mkdir -p /vol/data /vol/files
COPY --chown=www-data:www-data assets/data/ /vol/data/
### ###
### PHP ### PHP
### ###
@ -120,10 +125,10 @@ RUN crontab -u www-data /root/crontab
### ###
# push the fixed systemd file for redis # push the fixed systemd file for redis
COPY bugfix/redis.service /etc/systemd/system/redis.service COPY assets/bugfix/redis-server.service /etc/systemd/system/redis-server.service
COPY bugfix/apache2.override /etc/systemd/system/apache2.service.d/override.conf COPY assets/bugfix/apache2.override /etc/systemd/system/apache2.service.d/override.conf
# bugfix for cron # bugfix for cron
COPY bugfix/cronfix /root/ COPY assets/bugfix/cronfix /root/
RUN chmod +x /root/cronfix && /root/cronfix RUN chmod +x /root/cronfix && /root/cronfix

2
nextcloud/assets/bin/maint

@ -8,7 +8,7 @@ day=$(date +%d)
month=$(date +%m) month=$(date +%m)
year=$(date +%Y) year=$(date +%Y)
dumpdir=/vol/data dumpdir=/vol/data/sql
errlog=error/$year-$month-$day-T$hour.log errlog=error/$year-$month-$day-T$hour.log
mkdir -p $dumpdir/error mkdir -p $dumpdir/error

10
nextcloud/assets/data/host.config.php

@ -0,0 +1,10 @@
<?php
$CONFIG = array(
'trusted_domains' =>
array (
0 => 'example.domain.com',
),
'overwriteprotocol' => 'https',
'overwritehost' => 'example.domain.com',
'overwritewebroot' => '/nextcloud',
);
Loading…
Cancel
Save