Skip to content

Commit

Permalink
Merge pull request #58 from SiaFoundation/nate/fix-dockerfile
Browse files Browse the repository at this point in the history
Fix docker build error
  • Loading branch information
n8maninger authored Feb 26, 2024
2 parents 4fda367 + 7d1ea9f commit ec42452
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,10 +1,13 @@
FROM docker.io/library/golang:1.20 AS builder
FROM docker.io/library/golang:1.21 AS builder

WORKDIR /walletd

COPY . .
# build
RUN go build -o bin/ -tags='netgo timetzdata' -trimpath -a -ldflags '-s -w' ./cmd/walletd

# Enable CGO for sqlite3 support
ENV CGO_ENABLED=1

RUN go build -o bin/ -tags='netgo timetzdata' -trimpath -a -ldflags '-s -w -linkmode external -extldflags "-static"' ./cmd/walletd

FROM docker.io/library/alpine:3
LABEL maintainer="The Sia Foundation <[email protected]>" \
Expand Down

0 comments on commit ec42452

Please sign in to comment.