Add docker-entry

This commit is contained in:
Glenn Y. Rolland 2018-12-25 11:40:50 +01:00
parent 7ec2679072
commit f7b412dfc7
2 changed files with 20 additions and 4 deletions

View file

@ -1,6 +1,4 @@
#FROM owncloud:10.0.4
FROM nextcloud:12.0.4
#FROM nextcloud:13
FROM owncloud:10.0.10
RUN apt-get update && \
apt-get install -q -y cron && \
@ -8,5 +6,6 @@ RUN apt-get update && \
RUN echo "*/15 * * * * root su -l www-data -s /bin/bash -c 'php -f /var/www/html/cron.php' > /dev/null 2>&1" >> /etc/crontab
CMD cron && apache2-foreground
COPY docker-entry.sh /docker-entry.sh
CMD /docker-entry.sh

17
docker-entry.sh Normal file
View file

@ -0,0 +1,17 @@
#!/bin/sh
# Add htaccess configuration
cat >> /var/www/html/.htaccess <<MARK
<IfModule mod_proxy.c>
ProxyPass /sites/ http://localhost/index.php/apps/cms_pico/pico/
ProxyPassReverse /sites/ http://localhost/index.php/apps/cms_pico/pico/
</IfModule>
MARK
# Enable apache modules
a2enmod proxy rewrite
# Run service
cron
exec apache2-foreground