From 5202715dbacdf02ee197ceb928281daa6236859b Mon Sep 17 00:00:00 2001 From: Acid Date: Wed, 13 May 2026 23:05:53 -0400 Subject: [PATCH] docker --- .gitignore | 2 ++ Dockerfile | 20 ++++++++++++++++++++ docker-compose.yml | 10 ++++++++++ 3 files changed, 32 insertions(+) create mode 100644 Dockerfile create mode 100644 docker-compose.yml diff --git a/.gitignore b/.gitignore index c7c3759..8b59ef4 100644 --- a/.gitignore +++ b/.gitignore @@ -5,3 +5,5 @@ db.sqlite3 __pycache__ **__pycache__** test.py +binary +tmp/ diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..5e6a7b4 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,20 @@ +FROM golang:alpine AS builder + +WORKDIR /app + +COPY go.mod ./ +COPY *.go ./ + +RUN go build -o server . + +FROM alpine:latest + +WORKDIR /app + +COPY --from=builder /app/server . +COPY static/ static/ +COPY templates/ templates/ + +EXPOSE 8080 + +CMD ["./server"] diff --git a/docker-compose.yml b/docker-compose.yml new file mode 100644 index 0000000..2401553 --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1,10 @@ +services: + website: + build: + context: . + dockerfile: Dockerfile + image: acidarchon.com + container_name: acidarchon.com + ports: + - 8088:8080 + restart: unless-stopped