Revert "remove cron and base off dpedu/base"

This reverts commit a89cb8d89c.
This commit is contained in:
dave 2016-05-15 16:21:37 -07:00
parent a89cb8d89c
commit bb93f396e1
2 changed files with 10 additions and 2 deletions

View File

@ -1,6 +1,8 @@
FROM dpedu/base FROM ubuntu:14.04
MAINTAINER Dave P MAINTAINER Dave P
# Admin user
RUN useradd --create-home --groups sudo admin ; echo "admin:admin" | chpasswd ; locale-gen en
# ZNC user # ZNC user
RUN useradd --create-home znc ; echo "znc:znc" | chpasswd RUN useradd --create-home znc ; echo "znc:znc" | chpasswd
@ -11,7 +13,7 @@ RUN mkdir /var/run/sshd ; apt-get update ; apt-get install -y supervisor vim ope
RUN su -c 'cd /home/znc ; apt-get source znc' znc RUN su -c 'cd /home/znc ; apt-get source znc' znc
# Set nginx workers to a low number # Set nginx workers to a low number
RUN sed -i -e"s/^worker_processes\s*4/worker_processes 2/" /etc/nginx/nginx.conf RUN sed -i -e"s/^worker_processes\s*4/worker_processes 1/" /etc/nginx/nginx.conf
# Set nginx user to ZNC user # Set nginx user to ZNC user
RUN sed -i -e"s/^user\s*www\-data/user znc/" /etc/nginx/nginx.conf RUN sed -i -e"s/^user\s*www\-data/user znc/" /etc/nginx/nginx.conf
# Turn off nginx daemon mode # Turn off nginx daemon mode
@ -32,6 +34,7 @@ RUN rm /tmp/crontab
# Install startup stuff # Install startup stuff
COPY supervisor.conf /etc/supervisor/conf.d/supervisor.conf COPY supervisor.conf /etc/supervisor/conf.d/supervisor.conf
COPY nginx.conf /etc/supervisor/conf.d/nginx.conf COPY nginx.conf /etc/supervisor/conf.d/nginx.conf
COPY cron.conf /etc/supervisor/conf.d/cron.conf
COPY znc.conf /etc/supervisor/conf.d/znc.conf COPY znc.conf /etc/supervisor/conf.d/znc.conf
COPY sshd.conf /etc/supervisor/conf.d/sshd.conf COPY sshd.conf /etc/supervisor/conf.d/sshd.conf
COPY start /start COPY start /start
@ -41,3 +44,4 @@ RUN chmod +x /start
EXPOSE 22 EXPOSE 22
# nginx # nginx
EXPOSE 80 EXPOSE 80

4
cron.conf Normal file
View File

@ -0,0 +1,4 @@
[program:cron]
command=/usr/sbin/cron -f
autorestart=true