Skip to content

Commit 9bdab19

Browse files
committed
Wait for docker to start before running dapper
Signed-off-by: Brad Davidson <[email protected]>
1 parent 20dda23 commit 9bdab19

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

Makefile

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
TARGETS := $(shell ls scripts | grep -v \\.sh)
22
GO_FILES ?= $$(find . -name '*.go' | grep -v generated)
3+
SHELL := /bin/bash
34

45

56
.dapper:
@@ -9,7 +10,11 @@ GO_FILES ?= $$(find . -name '*.go' | grep -v generated)
910
@./.dapper.tmp -v
1011
@mv .dapper.tmp .dapper
1112

12-
$(TARGETS): .dapper
13+
.PHONY: docker.sock
14+
docker.sock:
15+
while ! docker version 1>/dev/null; do sleep 1; done
16+
17+
$(TARGETS): .dapper docker.sock
1318
./.dapper $@
1419

1520
.PHONY: deps
@@ -42,4 +47,4 @@ format:
4247
local:
4348
DOCKER_BUILDKIT=1 docker build \
4449
--build-arg="REPO TAG GITHUB_TOKEN GOLANG GOCOVER DEBUG" \
45-
-t k3s-local -f Dockerfile.local --output=. .
50+
-t k3s-local -f Dockerfile.local --output=. .

0 commit comments

Comments
 (0)