This commit is contained in:
parent
68d706c2d6
commit
0b9227648b
1 changed files with 16 additions and 3 deletions
|
|
@ -66,9 +66,22 @@ jobs:
|
||||||
if [ -z "$TAG" ]; then
|
if [ -z "$TAG" ]; then
|
||||||
TAG="latest"
|
TAG="latest"
|
||||||
fi
|
fi
|
||||||
# Configure Docker DNS and build
|
# Configure Docker daemon with DNS
|
||||||
mkdir -p ~/.docker
|
mkdir -p ~/.docker
|
||||||
echo '{"dns": ["8.8.8.8", "1.1.1.1"]}' > ~/.docker/daemon.json
|
cat > ~/.docker/daemon.json << 'EOF'
|
||||||
docker build -t registry.derickphan.com/tinyweb:$TAG .
|
{
|
||||||
|
"dns": ["8.8.8.8", "1.1.1.1"],
|
||||||
|
"builder": {
|
||||||
|
"features": {
|
||||||
|
"buildkit": true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
EOF
|
||||||
|
# Restart docker to pick up new config
|
||||||
|
pkill dockerd || true
|
||||||
|
sleep 2
|
||||||
|
# Build with buildkit
|
||||||
|
DOCKER_BUILDKIT=1 docker build --network=host -t registry.derickphan.com/tinyweb:$TAG .
|
||||||
docker push registry.derickphan.com/tinyweb:$TAG
|
docker push registry.derickphan.com/tinyweb:$TAG
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue