-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
7 changed files
with
61 additions
and
78 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,22 @@ | ||
FROM docker.io/golang:1.21-alpine AS backend_builder | ||
WORKDIR /app | ||
RUN apk add git | ||
COPY go.mod go.sum ./ | ||
RUN go mod download && go mod verify | ||
COPY cmd ./cmd | ||
COPY internal ./internal | ||
RUN go build -v ./cmd/panorama | ||
|
||
FROM docker.io/node:18-alpine AS ui_builder | ||
WORKDIR /app/ui | ||
COPY ui/package*.json ./ | ||
RUN npm install | ||
COPY ui . | ||
RUN npm run build | ||
|
||
FROM docker.io/golang:1.22-alpine AS backend_builder | ||
WORKDIR /app | ||
RUN apk add git | ||
COPY go.mod go.sum main.go ./ | ||
RUN go mod download && go mod verify | ||
COPY --from=ui_builder /app/ui/build /app/ui/build | ||
COPY internal ./internal | ||
RUN go build -v | ||
|
||
FROM scratch | ||
WORKDIR /app | ||
COPY --from=backend_builder /app/panorama ./ | ||
COPY --from=ui_builder /app/ui/build static | ||
COPY config.example.toml /etc/panorama/config.toml | ||
|
||
ENTRYPOINT ["./panorama", "run", "--config", "/etc/panorama/config.toml"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters