-
Notifications
You must be signed in to change notification settings - Fork 175
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
use alpine:latest, build go 1.16 from source (#699)
* use alpine:latest, build go 1.16 from source Signed-off-by: jnichols <[email protected]> * codespell Signed-off-by: jnichols <[email protected]> --------- Signed-off-by: jnichols <[email protected]>
- Loading branch information
1 parent
ec87a9a
commit 4c8c8de
Showing
19 changed files
with
38 additions
and
25 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,26 @@ | ||
ARG IMAGE_ARCH=amd64 | ||
|
||
FROM golang:1.14.3 as builder | ||
FROM alpine:latest as builder | ||
RUN apk add --no-cache bash gcc musl-dev openssl go make; | ||
RUN export \ | ||
GOROOT_BOOTSTRAP="$(go env GOROOT)" \ | ||
GOOS="$(go env GOOS)" \ | ||
GOARCH="$(go env GOARCH)" \ | ||
GOHOSTOS="$(go env GOHOSTOS)" \ | ||
GOHOSTARCH="$(go env GOHOSTARCH)"; | ||
RUN wget -O go.src.tar.gz https://go.dev/dl/go1.16.15.src.tar.gz; \ | ||
echo '90a08c689279e35f3865ba510998c33a63255c36089b3ec206c912fc0568c3d3 *go.src.tar.gz' | sha256sum -c -; \ | ||
tar -C /usr/local -xzf go.src.tar.gz; \ | ||
rm go.src.tar.gz; \ | ||
cd /usr/local/go/src; \ | ||
./make.bash; | ||
COPY . /go/src/github.com/trickstercache/trickster | ||
WORKDIR /go/src/github.com/trickstercache/trickster | ||
|
||
ARG GOARCH=amd64 | ||
RUN GOOS=linux GOARCH=${GOARCH} CGO_ENABLED=0 make build | ||
|
||
FROM ${IMAGE_ARCH}/alpine:3.12 | ||
FROM ${IMAGE_ARCH}/alpine:latest | ||
LABEL maintainer "The Trickster Authors <[email protected]>" | ||
|
||
COPY --from=builder /go/src/github.com/trickstercache/trickster/OPATH/trickster /usr/local/bin/trickster | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters