use local protos

This commit is contained in:
Elio Bischof
2025-06-23 16:13:48 +02:00
parent 2924961378
commit cd37f8c7b7
6 changed files with 25 additions and 0 deletions

View File

@@ -183,4 +183,5 @@ login-ensure-remote:
@git remote -v | grep $(LOGIN_REMOTE_NAME) || \
git remote add $(LOGIN_REMOTE_NAME) $(LOGIN_REMOTE_URL)
LOGIN_BAKE_CLI ?= docker buildx bake --file ./docker-bake.hcl
include login/Makefile

12
docker-bake.hcl Normal file
View File

@@ -0,0 +1,12 @@
include = ["login/docker-bake.hcl"]
target "proto-files" {
dockerfile = "dockerfiles/proto-files.Dockerfile"
}
target "typescript-proto-client" {
dockerfile = "dockerfiles/typescript-proto-client.Dockerfile"
contexts = {
proto-files = "target:proto-files"
}
}

View File

@@ -0,0 +1,2 @@
FROM scratch AS proto-files
COPY ./proto /

View File

@@ -0,0 +1,2 @@
*
!proto

View File

@@ -0,0 +1,6 @@
FROM login-pnpm AS typescript-proto-client
COPY ./login/packages/zitadel-proto/package.json ./packages/zitadel-proto/
RUN --mount=type=cache,id=pnpm,target=/pnpm/store \
pnpm install --frozen-lockfile --workspace-root --filter zitadel-proto
COPY --from=proto-files / /proto-files
RUN cd packages/zitadel-proto && pnpm exec buf generate /proto-files --path ./proto/zitadel

View File

@@ -0,0 +1,2 @@
*
!/packages/zitadel-proto/