Browse Source

First commit with first versions

Jindrich Skacel 6 years ago
commit
0ac8865dcb
5 changed files with 98 additions and 0 deletions
  1. 4 0
      README.md
  2. 10 0
      alpine/Dockerfile
  3. 13 0
      haproxy/Dockerfile
  4. 20 0
      nginx/Dockerfile
  5. 51 0
      php/Dockerfile

+ 4 - 0
README.md

@@ -0,0 +1,4 @@
+Bunch of docker files for ARM architecture
+
+*Tested on:*
+- Odroid C2

+ 10 - 0
alpine/Dockerfile

@@ -0,0 +1,10 @@
+# alpine up to date
+#
+# VERSION 0.1
+
+FROM 	armbuild/alpine
+
+# Base packages
+RUN apk --update upgrade && rm -rf /var/cache/apk/*
+
+CMD ["/bin/sh"] 

+ 13 - 0
haproxy/Dockerfile

@@ -0,0 +1,13 @@
+# haproxy
+#
+# VERSION 0.1
+
+FROM 	ronnicek/alpine:latest
+
+# Base packages
+RUN apk --update add haproxy && \
+		 rm -rf /var/cache/apk/*
+
+RUN mkdir -p /usr/share/haproxy/ && chown -R haproxy:haproxy /usr/share/haproxy/
+
+CMD ["haproxy", "-f", "/usr/local/etc/haproxy/haproxy.cfg"]

+ 20 - 0
nginx/Dockerfile

@@ -0,0 +1,20 @@
+# nginx
+#
+# VERSION 0.1
+
+FROM 	ronnicek/alpine:latest
+
+# Base packages
+RUN apk --update add nginx && \
+		 rm -rf /var/cache/apk/*
+
+# forward request and error logs to docker log collector
+RUN ln -sf /dev/stdout /var/log/nginx/access.log \
+	&& ln -sf /dev/stderr /var/log/nginx/error.log \
+	&& mkdir -p /run/nginx/ \
+	&& mkdir -p /var/lib/nginx/tmp/ \
+	&& chown nobody /var/lib/nginx && chown -R nobody /var/lib/nginx/tmp/
+
+EXPOSE 80 443
+
+CMD ["nginx", "-g", "daemon off;"]

+ 51 - 0
php/Dockerfile

@@ -0,0 +1,51 @@
+# php5-base
+#
+# VERSION 0.1
+
+FROM 	ronnicek/alpine:latest
+
+# Base packages
+RUN 	apk --update add php5-mcrypt \
+											php5-soap \
+											php5-openssl \
+											php5-gmp \
+											php5-pdo_odbc \
+											php5-json \
+											php5-dom \
+											php5-pdo \
+											php5-zip \
+											php5-mysql \
+											php5-sqlite3 \
+											php5-apcu \
+											php5-pdo_pgsql \
+											php5-bcmath \
+											php5-gd \
+											php5-xcache \
+											php5-odbc \
+											php5-pdo_mysql \
+											php5-pdo_sqlite \
+											php5-gettext \
+											php5-xmlreader \
+											php5-xmlrpc \
+											php5-bz2 \
+											php5-memcache \
+											php5-mssql \
+											php5-iconv \
+											php5-pdo_dblib \
+											php5-curl \
+											php5-ctype \
+											php5-zlib \
+											php5-fpm && \
+											rm -rf /var/cache/apk/*
+
+RUN set -xe && \
+	cd /etc/php5/ && \
+	sed 's/;include=/include=/g' php-fpm.conf > php-fpm.conf.bak && \
+	sed 's/\/var\/log\/php-fpm.log/\/proc\/self\/fd\/2/g' php-fpm.conf.bak > php-fpm.conf && \
+	sed 's/;daemonize = yes/daemonize = no/g' php-fpm.conf > php-fpm.conf.bak && \
+	sed 's/listen = 127.0.0.1:9000/listen = [::]:9000/g' php-fpm.conf.bak > php-fpm.conf && \
+	sed 's/;env/env/g' php-fpm.conf > php-fpm.conf.bak && mv php-fpm.conf.bak php-fpm.conf
+
+EXPOSE 9000
+
+CMD ["/usr/bin/php-fpm"]