move workspace templates to repo root and auto-sync into embed path at build time

This commit is contained in:
DBT
2026-02-24 04:54:12 +00:00
parent 78b6f6fdf6
commit 0470a1bbe0
11 changed files with 50 additions and 97 deletions

13
Dockerfile.test Normal file
View File

@@ -0,0 +1,13 @@
FROM golang:alpine AS builder
WORKDIR /app
COPY go.mod go.sum ./
RUN go mod download
COPY . .
# Sync root workspace templates into embed path before build
RUN rm -rf ./cmd/clawgo/workspace && mkdir -p ./cmd/clawgo/workspace && cp -a ./workspace/. ./cmd/clawgo/workspace/
RUN go build -o clawgo ./cmd/clawgo
FROM alpine:latest
WORKDIR /root/
COPY --from=builder /app/clawgo .
CMD ["./clawgo"]