Skip to content

Commit 097d5db

Browse files
committed
🐛 fix: Update Dockerfile
1 parent 6f88600 commit 097d5db

File tree

2 files changed

+3
-20
lines changed

2 files changed

+3
-20
lines changed

.goreleaser.yaml

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,6 @@
11
# yaml-language-server: $schema=https://goreleaser.com/static/schema.json
22
version: 2
33

4-
before:
5-
hooks:
6-
- go mod tidy
7-
- go fmt ./...
8-
- go generate ./...
9-
104
builds:
115
- id: semantic-search-api
126
main: ./cmd/main.go

Dockerfile

Lines changed: 3 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,5 @@
1-
FROM golang:1.24-alpine AS builder
1+
FROM gcr.io/distroless/static:nonroot
22

3-
WORKDIR /app
3+
COPY semantic-search-api /semantic-search-api
44

5-
COPY go.mod go.sum ./
6-
RUN go mod download
7-
8-
COPY . .
9-
10-
RUN go build -o semantic-search-api ./cmd/main.go
11-
12-
FROM scratch
13-
14-
COPY --from=builder /app/semantic-search-api /semantic-search-api
15-
16-
ENTRYPOINT ["/semantic-search"]
5+
ENTRYPOINT [ "/semantic-search-api" ]

0 commit comments

Comments
 (0)