forked from pi-hole/docker-pi-hole
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcircle-test.sh
executable file
·30 lines (25 loc) · 900 Bytes
/
circle-test.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
#!/usr/bin/env bash
set -ex
# Circle CI Job for single architecture
# setup qemu/variables
docker run --rm --privileged multiarch/qemu-user-static:register --reset > /dev/null
. circle-vars.sh
if [[ "$1" == "enter" ]]; then
enter="-it --entrypoint=sh"
fi
# generate and build dockerfile
docker build -t image_pipenv -f Dockerfile_build .
env > /tmp/env
docker run --rm \
-v /var/run/docker.sock:/var/run/docker.sock \
-v "$(pwd):/$(pwd)" \
-w "$(pwd)" \
-e PIPENV_CACHE_DIR="$(pwd)/.pipenv" \
--env-file /tmp/env \
$enter image_pipenv
# docker run --rm -v /var/run/docker.sock:/var/run/docker.sock -v "$(pwd):/$(pwd)" -w "$(pwd)" --env-file /tmp/env image_pipenv /ws/Dockerfile.sh
docker images
echo $DOCKERHUB_PASS | docker login --username=$DOCKERHUB_USER --password-stdin
docker push $ARCH_IMAGE
mkdir -p ci-workspace
echo "$ARCH_IMAGE" | tee ./ci-workspace/$ARCH