Skip to content

Commit 2b74636

Browse files
committed
Restore import path with uppercase characters
I wasn't able to reproduce the issue described in GoogleContainerTools#5492 and GoogleContainerTools#5505, so this change restores the import path with the uppercase characters and the `ko://` prefix in the custom build example. I had to tweak some values to get the integration tests to run, because I don't have access to the `k8s-skaffold` project. Let's see if the build passes. Additional minor changes: - Bump the ko version in the custom build example. - Add the full path to the ko binary in the custom build script, in case `$GOPATH/bin` is not on the `PATH`. Once we move to Go 1.16 for our builds, we can use the `go install` command to install ko in the custom build shell script.
1 parent a829fe3 commit 2b74636

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

integration/examples/custom/build.sh

+3-2
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,12 @@ set -e
33

44
if ! [ -x "$(command -v ko)" ]; then
55
pushd $(mktemp -d)
6-
go mod init tmp; GOFLAGS= go get github.com/google/ko/cmd/ko@v0.6.0
6+
curl -L https://github.com/google/ko/archive/v0.8.3.tar.gz | tar --strip-components 1 -zx
7+
go build -o $(go env GOPATH)/bin/ko .
78
popd
89
fi
910

10-
output=$(ko publish --local --preserve-import-paths --tags= . | tee)
11+
output=$($(go env GOPATH)/bin/ko publish --local --preserve-import-paths --tags= . | tee)
1112
ref=$(echo "$output" | tail -n1)
1213

1314
docker tag "$ref" "$IMAGE"

integration/examples/custom/skaffold.yaml

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ apiVersion: skaffold/v2beta20
22
kind: Config
33
build:
44
artifacts:
5-
- image: github.com/googlecontainertools/skaffold/examples/custom
5+
- image: ko://github.com/GoogleContainerTools/skaffold/examples/custom
66
custom:
77
buildCommand: ./build.sh
88
dependencies:

0 commit comments

Comments
 (0)