Dockerfile 993 B

12345678910111213141516171819202122232425262728293031
  1. FROM cloudron/base:0.3.0
  2. MAINTAINER Girish Ramakrishnan <girish@forwardbias.in>
  3. ENV DEBIAN_FRONTEND noninteractive
  4. RUN mkdir -p /app/code
  5. WORKDIR /app/code
  6. RUN curl -L http://wordpress.org/wordpress-4.2.tar.gz | tar -xz --strip-components 1 -f -
  7. RUN chown -R www-data.www-data /app/code
  8. ADD start.sh /app/code/start.sh
  9. RUN chmod +x /app/code/start.sh
  10. RUN curl -o /app/code/wp https://raw.githubusercontent.com/wp-cli/builds/gh-pages/phar/wp-cli.phar
  11. RUN chmod +x /app/code/wp
  12. RUN ln -sf /app/data/wp-config.php /app/code/wp-config.php
  13. # configure apache
  14. RUN rm /etc/apache2/sites-enabled/*
  15. RUN sed -i 's/upload_max_filesize = .*/upload_max_filesize = 8M/' /etc/php5/apache2/php.ini
  16. ADD apache2-wordpress.conf /etc/apache2/sites-available/wordpress.conf
  17. RUN ln -sf /etc/apache2/sites-available/wordpress.conf /etc/apache2/sites-enabled/wordpress.conf
  18. RUN a2enmod php5
  19. # supervisor
  20. ADD supervisor-apache2.conf /etc/supervisor/conf.d/apache2.conf
  21. EXPOSE 80
  22. CMD [ "/app/code/start.sh" ]