Dockerfile 1.2 KB

12345678910111213141516171819202122232425262728293031323334
  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 curl -L -o /app/code/wp-oauth.zip https://github.com//cloudron-io/WP-OAuth/archive/master.zip
  13. RUN ln -sf /app/data/wp-config.php /app/code/wp-config.php
  14. RUN curl -L -o /app/code/disable-wordpress-updates.zip https://downloads.wordpress.org/plugin/disable-wordpress-updates.zip
  15. # configure apache
  16. RUN rm /etc/apache2/sites-enabled/*
  17. RUN sed -i 's/upload_max_filesize = .*/upload_max_filesize = 8M/' /etc/php5/apache2/php.ini
  18. ADD apache2-wordpress.conf /etc/apache2/sites-available/wordpress.conf
  19. RUN ln -sf /etc/apache2/sites-available/wordpress.conf /etc/apache2/sites-enabled/wordpress.conf
  20. RUN a2enmod php5
  21. # supervisor
  22. ADD supervisor-apache2.conf /etc/supervisor/conf.d/apache2.conf
  23. EXPOSE 80
  24. CMD [ "/app/code/start.sh" ]