Skip to content

Commit b72f8cf

Browse files
committed
fix: allow 'make dev-docker' with go.work
1 parent 500487f commit b72f8cf

File tree

3 files changed

+7
-5
lines changed

3 files changed

+7
-5
lines changed

.woodpecker.star

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1654,6 +1654,7 @@ def dockerRelease(ctx, repo, build_type):
16541654
"name": "dryrun",
16551655
"image": PLUGINS_DOCKER_BUILDX,
16561656
"settings": {
1657+
"context": "..",
16571658
"dry_run": True,
16581659
"platforms": "linux/amd64", # do dry run only on the native platform
16591660
"repo": "%s,quay.io/%s" % (repo, repo),
@@ -1676,6 +1677,7 @@ def dockerRelease(ctx, repo, build_type):
16761677
"name": "build-and-push",
16771678
"image": PLUGINS_DOCKER_BUILDX,
16781679
"settings": {
1680+
"context": "..",
16791681
"repo": "%s,quay.io/%s" % (repo, repo),
16801682
"platforms": "linux/amd64,linux/arm64", # we can add remote builders
16811683
"auto_tag": False if build_type == "daily" else True,

opencloud/Makefile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ include ../.make/docs.mk
1717

1818
.PHONY: dev-docker
1919
dev-docker:
20-
docker build -f docker/Dockerfile.multiarch -t opencloudeu/opencloud:dev ..
20+
docker build -f docker/Dockerfile.multiarch -t opencloudeu/opencloud:dev ../..
2121

2222
.PHONY: dev-docker-multiarch
2323
dev-docker-multiarch:
@@ -28,7 +28,7 @@ dev-docker-multiarch:
2828
docker buildx rm opencloudbuilder || true
2929
docker buildx create --platform linux/arm64,linux/amd64 --name opencloudbuilder
3030
docker buildx use opencloudbuilder
31-
cd .. && docker buildx build --platform linux/arm64,linux/amd64 --output type=docker --file opencloud/docker/Dockerfile.multiarch --tag opencloudeu/opencloud:dev-multiarch .
31+
docker buildx build --platform linux/arm64,linux/amd64 --output type=docker --file docker/Dockerfile.multiarch --tag opencloudeu/opencloud:dev-multiarch ../..
3232
docker buildx rm opencloudbuilder
3333

3434
.PHONY: debug-docker

opencloud/docker/Dockerfile.multiarch

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,12 +6,12 @@ ARG STRING
66

77
RUN apk add bash make git curl gcc musl-dev libc-dev binutils-gold inotify-tools vips-dev
88

9-
WORKDIR /opencloud
10-
RUN --mount=type=bind,target=/opencloud \
9+
WORKDIR /build
10+
RUN --mount=type=bind,target=/build,rw \
1111
--mount=type=cache,target=/go/pkg/mod \
1212
--mount=type=cache,target=/root/.cache \
1313
GOOS="${TARGETOS:-linux}" GOARCH="${TARGETARCH:-amd64}" ; \
14-
make -C opencloud release-linux-docker-${TARGETARCH} ENABLE_VIPS=true DIST=/dist
14+
make -C opencloud/opencloud release-linux-docker-${TARGETARCH} ENABLE_VIPS=true DIST=/dist
1515

1616
FROM alpine:3.21
1717
ARG VERSION

0 commit comments

Comments
 (0)