Skip to content

Commit

Permalink
Merge pull request #778 from onflow/vishal/dockerfile_v17
Browse files Browse the repository at this point in the history
merging in changes for node software version from master
  • Loading branch information
Kay-Zee committed Jun 2, 2021
2 parents 1a5f447 + 4e3487c commit 3accb5f
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions cmd/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,9 @@ WORKDIR /app
RUN --mount=type=cache,target=/go/pkg/mod \
--mount=type=cache,target=/root/.cache/go-build \
--mount=type=ssh \
GO111MODULE=on CGO_ENABLED=1 GOOS=linux GOARCH=amd64 go build --tags "relic,netgo" -ldflags "-extldflags -static" -o ./app ./cmd/${TARGET}
GO111MODULE=on CGO_ENABLED=1 GOOS=linux GOARCH=amd64 go build --tags "relic,netgo" -ldflags "-extldflags -static \
-X 'github.com/onflow/flow-go/cmd/build.commit=${COMMIT}' -X 'github.com/onflow/flow-go/cmd/build.semver=${VERSION}'" \
-o ./app ./cmd/${TARGET}

RUN chmod a+x /app/app

Expand All @@ -66,7 +68,9 @@ WORKDIR /app
RUN --mount=type=ssh \
--mount=type=cache,target=/go/pkg/mod \
--mount=type=cache,target=/root/.cache/go-build \
GO111MODULE=on CGO_ENABLED=1 GOOS=linux GOARCH=amd64 go build --tags "relic,netgo" -ldflags "-extldflags -static" -gcflags="all=-N -l" -o ./app ./cmd/${TARGET}
GO111MODULE=on CGO_ENABLED=1 GOOS=linux GOARCH=amd64 go build --tags "relic,netgo" -ldflags "-extldflags -static \
-X 'github.com/onflow/flow-go/cmd/build.commit=${COMMIT}' -X 'github.com/onflow/flow-go/cmd/build.semver=${VERSION}'" \
-gcflags="all=-N -l" -o ./app ./cmd/${TARGET}

RUN chmod a+x /app/app

Expand All @@ -85,7 +89,7 @@ RUN --mount=type=cache,target=/go/pkg/mod \
--mount=type=cache,target=/root/.cache/go-build \
--mount=type=ssh \
GO111MODULE=on CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags "-extldflags -static \
-X 'github.com/onflow/flow-go/cmd/bootstrap/build.commit=${COMMIT}' -X 'github.com/onflow/flow-go/cmd/bootstrap/build.semver=${VERSION}'" \
-X 'github.com/onflow/flow-go/cmd/build.commit=${COMMIT}' -X 'github.com/onflow/flow-go/cmd/build.semver=${VERSION}'" \
-o ./app ./cmd/${TARGET}

RUN chmod a+x /app/app
Expand Down

0 comments on commit 3accb5f

Please sign in to comment.