Containerfile, composefile and makefile target for building images
This commit is contained in:
parent
0b11ac87cd
commit
64553bb153
3 changed files with 30 additions and 0 deletions
16
Containerfile
Normal file
16
Containerfile
Normal file
|
@ -0,0 +1,16 @@
|
|||
FROM docker.io/golang:1.24 AS builder
|
||||
WORKDIR /app
|
||||
COPY go.mod go.sum ./
|
||||
RUN go mod download
|
||||
COPY src src
|
||||
RUN GOOS=linux go build -o beretta src/*.go
|
||||
# FROM docker.io/alpine:3
|
||||
FROM docker.io/debian:bookworm-slim
|
||||
|
||||
RUN apt-get update && apt-get install -y \
|
||||
ca-certificates \
|
||||
sqlite3 \
|
||||
&& rm -rf /var/lib/apt/lists/*
|
||||
|
||||
COPY --from=builder /app/beretta /beretta
|
||||
ENTRYPOINT ["/beretta"]
|
Loading…
Add table
Add a link
Reference in a new issue