file_system/Dockerfile
root 0fb7557c27 Fix: Use docker/ prefix for all private registry images
- Updated all image paths to include docker/ prefix
- .gitlab-ci.yml: 192.168.1.154:31010/docker/alpine:latest
- Dockerfile: Both build and run stages use docker/alpine:latest
- Matches private registry structure where images are in docker/ directory

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-12-19 09:47:04 +08:00

38 lines
826 B
Docker

# Build Stage
FROM 192.168.1.154:31010/docker/alpine:latest AS builder
WORKDIR /app
# Install Go
RUN apk add --no-cache go
# Copy go mod and sum files
COPY go.mod go.sum ./
# Download all dependencies. Dependencies will be cached if the go.mod and go.sum files are not changed
RUN go mod download
# Copy the source from the current directory to the Working Directory inside the container
COPY . .
# Build the Go app
RUN go build -o server ./cmd/server
# Run Stage
FROM 192.168.1.154:31010/docker/alpine:latest
WORKDIR /app
# Copy the Pre-built binary from the previous stage
COPY --from=builder /app/server .
# Copy web resources
COPY --from=builder /app/web ./web
# Copy docs
COPY --from=builder /app/docs ./docs
# Expose port 8080 to the outside world
EXPOSE 8080
# Command to run the executable
CMD ["./server"]