diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..9c64030 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,7 @@ +FROM golang:latest AS build +WORKDIR /src +COPY . . +RUN CGO_ENABLED=0 go build ./cmd/bb + +FROM scratch AS bin +COPY --from=build /src/bb / \ No newline at end of file diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..48c239d --- /dev/null +++ b/Makefile @@ -0,0 +1,8 @@ +.PHONY: build +build: + DOCKER_BUILDKIT=1 + docker build --target bin --output bin/ . + +.PHONY: clean +clean: + rm bin/bb \ No newline at end of file