dalsze prace

master
Michał 'rysiek' Woźniak 2015-01-04 20:44:42 +01:00
parent 1cbd975b88
commit f037e4bdef
6 changed files with 57 additions and 9 deletions

29
nginx/Dockerfile Normal file
View File

@ -0,0 +1,29 @@
#
# Nginx Dockerfile
#
# based on https://github.com/dockerfile/nginx (licensed under MIT)
#
# Pull base image.
FROM debian:jessie
# Install Nginx.
RUN \
apt-get update && \
apt-get install -y nginx && \
echo "\ndaemon off;" >> /etc/nginx/nginx.conf && \
chown -R www-data:www-data /var/lib/nginx
# Define mountable directories.
VOLUME ["/etc/nginx/sites-enabled", "/etc/nginx/certs", "/etc/nginx/conf.d", "/var/log/nginx", "/var/www/html"]
# Define working directory.
WORKDIR /etc/nginx
# Expose ports.
EXPOSE 80
EXPOSE 443
# Define default command.
CMD []
ENTRYPOINT ["/usr/sbin/nginx"]

13
openldap/Dockerfile Normal file
View File

@ -0,0 +1,13 @@
FROM debian:jessie
MAINTAINER Michal "rysiek" Woźniak <rysiek@hackerspace.pl>
RUN LC_ALL=C DEBIAN_FRONTEND=noninteractive apt-get update && apt-get upgrade && apt-get install -y --no-install-recommends slapd ldap-utils openssl \
slapd ldapscripts ldap-utils ca-certificates ssl-cert
EXPOSE 389 636
# volumes: config data pid/socket
VOLUME ["/etc/ldap", "/var/lib/ldap", "/run/slapd"]
CMD []
ENTRYPOINT ["slapd", "-h", "ldap:/// ldapi:///", "-u", "openldap", "-g", "openldap", "-d0"]

View File

@ -54,7 +54,7 @@ RUN echo " \n\
******************************************************** \n\n\
"
VOLUME ["/var/run/phpfpm/", "/var/log/phpfpm/", "/opt/php"]
VOLUME ["/var/run/phpfpm", "/var/log/phpfpm", "/opt/php"]
CMD []
ENTRYPOINT ["/usr/sbin/php5-fpm", "-F", "--fpm-config", "/etc/php5/fpm/php-fpm.conf"]

View File

@ -18,13 +18,6 @@ RUN echo "deb http://apt.postgresql.org/pub/repos/apt/ jessie-pgdg main" > /etc/
# them by prefixing each apt-get statement with DEBIAN_FRONTEND=noninteractive
RUN export DEBIAN_FRONTEND=noninteractive && apt-get update && apt-get upgrade && apt-get install -y python-software-properties software-properties-common postgresql-9.3 postgresql-client-9.3 postgresql-contrib-9.3
# Note: The official Debian and Ubuntu images automatically ``apt-get clean``
# after each ``apt-get``
# Only quassel needs to connectm eh?
# TEMPORARY, NEED BETTER FIX
RUN echo "host any any 172.17.0.0/16 trust" >> /etc/postgresql/9.3/main/pg_hba.conf
# Well...
#RUN echo "listen_addresses='*'" >> /etc/postgresql/9.3/main/postgresql.conf
@ -37,7 +30,8 @@ RUN echo " \n\
\n\
******************************************************** \n\
REMEMBER TO RUN THE PREP SCRIPT: \n\
docker run --entrypoint /bin/sh -u root -t -i -v <volume>:/var/lib/postgresql/ --rm <plug/postgres> -c /root/prep.sh
docker run --entrypoint /bin/sh -u root -t -i -v <volume>:/var/lib/postgresql/ --rm <plug/postgres> -c /root/prep.sh \n\
******************************************************** \n\
"
# Expose the PostgreSQL port

View File

@ -17,6 +17,9 @@ chmod 0700 ./
# initdb as postgres
su -c '/usr/lib/postgresql/9.3/bin/initdb /var/lib/postgresql/9.3/main' postgres
# config
echo "host any any 172.17.0.0/16 trust" >> /etc/postgresql/9.3/main/pg_hba.conf
# create the needed databases
#/etc/init.d/postgresql start
#su -c 'psql --command "CREATE USER some_user;"' postgres

9
setup.sh Normal file
View File

@ -0,0 +1,9 @@
#!/bin/bash
#
# zestawianie całej magii
#
# budujemy nowy dom...
for img in images/*; do
docker build -t plug/$img $img
done