Updated all naming from LLM Proxy to GopherGate. Implemented new CSS-based branding and updated Go module/binary naming.
35 lines
596 B
Docker
35 lines
596 B
Docker
# Build stage
|
|
FROM golang:1.22-alpine AS builder
|
|
|
|
WORKDIR /app
|
|
|
|
# Copy go mod and sum files
|
|
COPY go.mod go.sum ./
|
|
RUN go mod download
|
|
|
|
# Copy the source code
|
|
COPY . .
|
|
|
|
# Build the application
|
|
RUN CGO_ENABLED=0 GOOS=linux go build -o gophergate ./cmd/gophergate
|
|
|
|
# Final stage
|
|
FROM alpine:latest
|
|
|
|
RUN apk --no-cache add ca-certificates tzdata
|
|
|
|
WORKDIR /app
|
|
|
|
# Copy the binary from the builder stage
|
|
COPY --from=builder /app/gophergate .
|
|
COPY --from=builder /app/static ./static
|
|
|
|
# Create data directory
|
|
RUN mkdir -p /app/data
|
|
|
|
# Expose port
|
|
EXPOSE 8080
|
|
|
|
# Run the application
|
|
CMD ["./gophergate"]
|