Skip to content

Commit 958fe02

Browse files
committed
Merge pull request WordPress#15 from infosiftr/clean-wordpress
Update to use the updated, official php:apache image.
2 parents aee0066 + 850c143 commit 958fe02

File tree

1 file changed

+1
-34
lines changed

1 file changed

+1
-34
lines changed

Dockerfile

Lines changed: 1 addition & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -1,37 +1,7 @@
1-
FROM debian:wheezy
1+
FROM php:5.6-apache
22

3-
RUN apt-get update && apt-get install -y \
4-
apache2 \
5-
curl \
6-
libapache2-mod-php5 \
7-
php5-curl \
8-
php5-gd \
9-
php5-mysql \
10-
rsync \
11-
wget \
12-
&& rm -rf /var/lib/apt/lists/*
133
RUN a2enmod rewrite
144

15-
# copy a few things from apache's init script that it requires to be setup
16-
ENV APACHE_CONFDIR /etc/apache2
17-
ENV APACHE_ENVVARS $APACHE_CONFDIR/envvars
18-
# and then a few more from $APACHE_CONFDIR/envvars itself
19-
ENV APACHE_RUN_USER www-data
20-
ENV APACHE_RUN_GROUP www-data
21-
ENV APACHE_RUN_DIR /var/run/apache2
22-
ENV APACHE_PID_FILE $APACHE_RUN_DIR/apache2.pid
23-
ENV APACHE_LOCK_DIR /var/lock/apache2
24-
ENV APACHE_LOG_DIR /var/log/apache2
25-
ENV LANG C
26-
RUN mkdir -p $APACHE_RUN_DIR $APACHE_LOCK_DIR $APACHE_LOG_DIR
27-
28-
# make CustomLog (access log) go to stdout instead of files
29-
# and ErrorLog to stderr
30-
RUN find "$APACHE_CONFDIR" -type f -exec sed -ri ' \
31-
s!^(\s*CustomLog)\s+\S+!\1 /proc/self/fd/1!g; \
32-
s!^(\s*ErrorLog)\s+\S+!\1 /proc/self/fd/2!g; \
33-
' '{}' ';'
34-
355
RUN rm -rf /var/www/html && mkdir /var/www/html
366
VOLUME /var/www/html
377
WORKDIR /var/www/html
@@ -42,9 +12,6 @@ ENV WORDPRESS_UPSTREAM_VERSION 4.0
4212
# upstream tarballs include ./wordpress/ so this gives us /usr/src/wordpress
4313
RUN curl -SL http://wordpress.org/wordpress-${WORDPRESS_UPSTREAM_VERSION}.tar.gz | tar -xzC /usr/src/
4414

45-
COPY docker-apache.conf /etc/apache2/sites-available/wordpress
46-
RUN a2dissite 000-default && a2ensite wordpress
47-
4815
COPY docker-entrypoint.sh /entrypoint.sh
4916

5017
ENTRYPOINT ["/entrypoint.sh"]

0 commit comments

Comments
 (0)