forked from visiblevc/wordpress-starter
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.sh
executable file
·31 lines (22 loc) · 823 Bytes
/
build.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
#!/usr/bin/env bash
npm_package_version="${npm_package_version?Script must be run using npm}"
docker login
[ $? -eq 1 ] && exit 0
# NOTE: Not building this stack of images concurrently due to a known issue
# with docker concurrent builds. https://github.com/moby/moby/issues/9656
docker build \
-t "visiblevc/wordpress:latest" \
-t "visiblevc/wordpress:latest-php7.1" \
-t "visiblevc/wordpress:$npm_package_version-php7.1" \
./php7.1/
docker build \
-t "visiblevc/wordpress:latest-php7.0" \
-t "visiblevc/wordpress:$npm_package_version-php7.0" \
./php7.0/
docker build \
-t "visiblevc/wordpress:latest-php5.6" \
-t "visiblevc/wordpress:$npm_package_version-php5.6" \
./php5.6/
echo "
Successfully built images with the following tags:"
docker images visiblevc/wordpress --format "{{.Tag}}" | sort -r