1
0
Fork 0

Initial import

This commit is contained in:
Daniele Tricoli 2015-02-15 04:37:57 +01:00
parent 62af52d1ba
commit 8fb29a75ef
3 changed files with 58 additions and 0 deletions

26
Dockerfile Normal file
View file

@ -0,0 +1,26 @@
FROM eriol/debian-i386:jessie
MAINTAINER Daniele Tricoli "eriol@mornie.org"
ENV LAST_UPDATE 2015-02-15
RUN apt-get update && apt-get -y --no-install-recommends install \
nginx \
owncloud \
php5-fpm \
php5-sqlite
RUN apt-get clean && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
RUN rm -f /etc/nginx/sites-enabled/default
ADD owncloud.conf /etc/nginx/sites-available/owncloud.conf
RUN ln -s /etc/nginx/sites-available/owncloud.conf /etc/nginx/sites-enabled/
RUN echo "cgi.fix_pathinfo = 0;" >> /etc/php5/fpm/php.ini
RUN echo "daemon off;" >> /etc/nginx/nginx.conf
ADD start.sh /start.sh
VOLUME ["/usr/share/owncloud/data"]
EXPOSE 80
ENTRYPOINT ["/start.sh"]

30
owncloud.conf Normal file
View file

@ -0,0 +1,30 @@
# ownCloud
server {
listen 80 default_server;
listen [::]:80 default_server;
server_name _;
root /usr/share/owncloud;
index index.php;
client_max_body_size 20M;
location ~ ^/(data|config|\.ht|db_structure\.xml|README) {
deny all;
}
location / {
try_files $uri $uri/ index.php;
}
location ~ \.php(?:$|/) {
fastcgi_split_path_info ^(.+\.php)(/.+)$;
include fastcgi_params;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
fastcgi_param PATH_INFO $fastcgi_path_info;
fastcgi_pass unix:/var/run/php5-fpm.sock;
}
}

2
start.sh Executable file
View file

@ -0,0 +1,2 @@
#!/bin/bash
/usr/sbin/php5-fpm -D && /usr/sbin/nginx