Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Dockerfile: use version for some utilities instead of commit-sha
The golangci-lint, gotestsum, shfmt, and vndr utilities should generally be ok to be pinned by version instead of a specific sha. Also rename the corresponding env-vars / build-args accordingly: - GOLANGCI_LINT_COMMIT -> GOLANGCI_LINT_VERSION - GOTESTSUM_COMMIT -> GOTESTSUM_VERSION - SHFMT_COMMIT -> SHFMT_VERSION - VNDR_COMMIT -> VNDR_VERSION - CONTAINERD_COMMIT -> CONTAINERD_VERSION - RUNC_COMMIT -> RUNC_VERSION - ROOTLESS_COMMIT -> ROOTLESS_VERSION Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
- Loading branch information
Showing
10 changed files
with
56 additions
and
43 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
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,10 +1,10 @@ | ||
#!/bin/sh | ||
|
||
: "${GOLANGCI_LINT_COMMIT=v1.23.8}" | ||
: "${GOLANGCI_LINT_VERSION=v1.23.8}" | ||
|
||
install_golangci_lint() { | ||
set -e | ||
export GO111MODULE=on | ||
GOBIN="${PREFIX}" go get "github.com/golangci/golangci-lint/cmd/golangci-lint@${GOLANGCI_LINT_COMMIT}" | ||
GOBIN="${PREFIX}" go get "github.com/golangci/golangci-lint/cmd/golangci-lint@${GOLANGCI_LINT_VERSION}" | ||
"${PREFIX}"/golangci-lint --version | ||
} |
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,9 +1,9 @@ | ||
#!/bin/sh | ||
|
||
: ${GOTESTSUM_COMMIT:=v0.5.3} | ||
: ${GOTESTSUM_VERSION:=v0.5.3} | ||
|
||
install_gotestsum() ( | ||
set -e | ||
export GO111MODULE=on | ||
GOBIN="${PREFIX}" go get "gotest.tools/gotestsum@${GOTESTSUM_COMMIT}" | ||
GOBIN="${PREFIX}" go get "gotest.tools/gotestsum@${GOTESTSUM_VERSION}" | ||
) |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,11 @@ | ||
#!/bin/sh | ||
|
||
: "${SHFMT_COMMIT:=01725bdd30658db1fe1b9e02173c3060061fe86f}" # v3.0.2 | ||
: "${SHFMT_VERSION:=v3.0.2}" | ||
|
||
install_shfmt() { | ||
echo "Install shfmt version $SHFMT_COMMIT" | ||
echo "Install shfmt version $SHFMT_VERSION" | ||
git clone https://github.com/mvdan/sh.git "$GOPATH/src/github.com/mvdan/sh" | ||
cd "$GOPATH/src/github.com/mvdan/sh" || exit 1 | ||
git checkout -q "$SHFMT_COMMIT" | ||
git checkout -q "$SHFMT_VERSION" | ||
GO111MODULE=on go build ${GO_BUILDMODE} -v -o "${PREFIX}/shfmt" ./cmd/shfmt | ||
} |
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,11 +1,11 @@ | ||
#!/bin/sh | ||
|
||
: "${VNDR_COMMIT:=f12b881cb8f081a5058408a58f429b9014833fc6}" # v0.1.2 | ||
: "${VNDR_VERSION:=v0.1.2}" | ||
|
||
install_vndr() { | ||
echo "Install vndr version $VNDR_COMMIT" | ||
echo "Install vndr version $VNDR_VERSION" | ||
git clone https://github.com/LK4D4/vndr.git "$GOPATH/src/github.com/LK4D4/vndr" | ||
cd "$GOPATH/src/github.com/LK4D4/vndr" || exit 1 | ||
git checkout -q "$VNDR_COMMIT" | ||
git checkout -q "$VNDR_VERSION" | ||
go build ${GO_BUILDMODE} -v -o "${PREFIX}/vndr" . | ||
} |