File tree Expand file tree Collapse file tree 2 files changed +7
-2
lines changed Expand file tree Collapse file tree 2 files changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -37,9 +37,10 @@ VOLUME /var/www/html
37
37
WORKDIR /var/www/html
38
38
39
39
ENV WORDPRESS_VERSION 4.0.0
40
+ ENV WORDPRESS_UPSTREAM_VERSION 4.0
40
41
41
42
# upstream tarballs include ./wordpress/ so this gives us /usr/src/wordpress
42
- RUN curl -SL http://wordpress.org/wordpress-$WORDPRESS_VERSION .tar.gz | tar -xzC /usr/src/
43
+ RUN curl -SL http://wordpress.org/wordpress-${WORDPRESS_UPSTREAM_VERSION} .tar.gz | tar -xzC /usr/src/
43
44
44
45
COPY docker-apache.conf /etc/apache2/sites-available/wordpress
45
46
RUN a2dissite 000-default && a2ensite wordpress
Original file line number Diff line number Diff line change 3
3
4
4
current=" $( curl -sSL ' http://api.wordpress.org/core/version-check/1.7/' | sed -r ' s/^.*"current":"([^"]+)".*$/\1/' ) "
5
5
6
+ upstream=" $current "
6
7
if [[ " $current " != * .* .* ]]; then
7
8
# turn "4.0" into "4.0.0"
8
9
current+=' .0'
9
10
fi
10
11
11
12
set -x
12
- sed -ri ' s/^(ENV WORDPRESS_VERSION) .*/\1 ' " $current " ' /' Dockerfile
13
+ sed -ri '
14
+ s/^(ENV WORDPRESS_VERSION) .*/\1 ' " $current " ' /;
15
+ s/^(ENV WORDPRESS_UPSTREAM_VERSION) .*/\1 ' " $upstream " ' /;
16
+ ' Dockerfile
You can’t perform that action at this time.
0 commit comments