Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 5 additions & 2 deletions server/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,16 @@ WORKDIR /app

# Copy go mod files
COPY go.mod go.sum ./
RUN go mod download

# Download dependencies with progress output
ENV GOPROXY=https://proxy.golang.org,direct
RUN go mod download -x

# Copy source code
COPY . .

# Build the application (CGO disabled for pure Go build)
RUN CGO_ENABLED=0 GOOS=linux go build -a -ldflags="-s -w" -o /app/cryptd-server ./cmd/server
RUN CGO_ENABLED=0 GOOS=linux go build -v -a -ldflags="-s -w" -o /app/cryptd-server ./cmd/server

# Runtime stage
FROM alpine:latest
Expand Down