Dockerfile 1023 B

1234567891011121314151617181920212223242526272829
  1. FROM cloudron/base:0.8.1
  2. MAINTAINER Johannes Zellner <johannes@cloudron.io>
  3. RUN mkdir -p /app/data /app/code /run/app/sessions
  4. WORKDIR /app/data
  5. # configure apache
  6. RUN rm /etc/apache2/sites-enabled/*
  7. RUN sed -e 's,^ErrorLog.*,ErrorLog "|/bin/cat",' -i /etc/apache2/apache2.conf
  8. RUN sed -e "s,MaxSpareServers[^:].*,MaxSpareServers 5," -i /etc/apache2/mods-available/mpm_prefork.conf
  9. RUN a2disconf other-vhosts-access-log
  10. RUN echo "Listen 8000" > /etc/apache2/ports.conf
  11. ADD apache2-app.conf /app/code/apache2-app.conf
  12. RUN ln -sf /app/data/apache2-app.conf /etc/apache2/sites-available/app.conf
  13. RUN ln -sf /etc/apache2/sites-available/app.conf /etc/apache2/sites-enabled/app.conf
  14. # configure mod_php
  15. RUN a2enmod php5
  16. RUN a2enmod rewrite
  17. RUN sed -e 's/upload_max_filesize = .*/upload_max_filesize = 8M/' \
  18. -e 's,;session.save_path.*,session.save_path = "/run/app/sessions",' \
  19. -i /etc/php5/apache2/php.ini
  20. ADD index.html /app/code/index.html
  21. ADD start.sh /app/code/start.sh
  22. CMD [ "/app/code/start.sh" ]