add docker build
This commit is contained in:
parent
5698d86756
commit
fa1b98365b
18 changed files with 686 additions and 0 deletions
17
docker/build.sh
Executable file
17
docker/build.sh
Executable file
|
|
@ -0,0 +1,17 @@
|
|||
#!/bin/sh
|
||||
cd `dirname $0`
|
||||
|
||||
HOST=`/sbin/ip route | grep docker0 | awk '{ print $9 }'`
|
||||
PORT=3142
|
||||
nc -z "$HOST" "$PORT" > /dev/null 2>&1
|
||||
result=$?
|
||||
if [ $result -eq 0 ] ; then
|
||||
proxy="--build-arg http_proxy=http://$HOST:$PORT"
|
||||
else
|
||||
proxy=
|
||||
fi
|
||||
|
||||
docker build $proxy -t 0x2620/pandora-base base
|
||||
docker build -t 0x2620/pandora-nginx nginx
|
||||
cd ..
|
||||
docker build -t 0x2620/pandora .
|
||||
Loading…
Add table
Add a link
Reference in a new issue