change hub file structure

This commit is contained in:
TOomaAh
2024-08-07 23:59:02 +02:00
parent 8a04a9bed6
commit d840178cc0
107 changed files with 5025 additions and 550 deletions

20
dockerfile_Agent Normal file
View File

@@ -0,0 +1,20 @@
FROM --platform=$BUILDPLATFORM golang:alpine AS builder
WORKDIR /app
# Download Go modules
COPY go.mod go.sum ./
RUN go mod download
COPY *.go ./
# Build
ARG TARGETOS TARGETARCH
RUN CGO_ENABLED=0 GOOS=$TARGETOS GOARCH=$TARGETARCH go build -ldflags "-w -s" -o /agent .
# ? -------------------------
FROM scratch
COPY --from=builder /agent /agent
ENTRYPOINT ["/agent"]