Init work
This commit is contained in:
13
Dockerfile
Normal file
13
Dockerfile
Normal file
@@ -0,0 +1,13 @@
|
||||
FROM golang:1.23-alpine AS build
|
||||
WORKDIR /src
|
||||
COPY go.mod go.sum ./
|
||||
RUN go mod download
|
||||
COPY main.go .
|
||||
RUN CGO_ENABLED=0 go build -o /todo-glance .
|
||||
|
||||
FROM alpine:3.21
|
||||
COPY --from=build /todo-glance /todo-glance
|
||||
VOLUME /data
|
||||
ENV TODO_DB_PATH=/data/todos.db
|
||||
EXPOSE 8081
|
||||
ENTRYPOINT ["/todo-glance"]
|
||||
Reference in New Issue
Block a user