Skip to content

Instantly share code, notes, and snippets.

@willbeason
Created December 10, 2020 19:42
Show Gist options
  • Save willbeason/e3e35dafd7c982b08a3bf365387e55c4 to your computer and use it in GitHub Desktop.
Save willbeason/e3e35dafd7c982b08a3bf365387e55c4 to your computer and use it in GitHub Desktop.
go run smoketest.go
hack$ go run smoketest.go
I1210 11:41:19.908940 3818346 smoketest.go:139] Run: Deploying CRDs
2020/12/10 11:41:19 exec: make -C ../examples/guestbook-operator install
make: Entering directory '/usr/local/google/home/willbeason/kubebuilder-declarative-pattern/examples/guestbook-operator'
/usr/local/google/home/willbeason/go/bin/controller-gen "crd:trivialVersions=true" rbac:roleName=manager-role webhook paths="./..." output:crd:artifacts:config=config/crd/bases
kustomize build config/crd | kubectl apply -f -
customresourcedefinition.apiextensions.k8s.io/guestbooks.addons.example.org configured
make: Leaving directory '/usr/local/google/home/willbeason/kubebuilder-declarative-pattern/examples/guestbook-operator'
I1210 11:41:21.549846 3818346 smoketest.go:143] Run: Deploying Operators
2020/12/10 11:41:21 exec: make -C ../examples/guestbook-operator docker-build docker-push deploy
make: Entering directory '/usr/local/google/home/willbeason/kubebuilder-declarative-pattern/examples/guestbook-operator'
go mod vendor
/usr/local/google/home/willbeason/go/bin/controller-gen object:headerFile=./hack/boilerplate.go.txt paths="./..."
go fmt ./...
go vet ./...
/usr/local/google/home/willbeason/go/bin/controller-gen "crd:trivialVersions=true" rbac:roleName=manager-role webhook paths="./..." output:crd:artifacts:config=config/crd/bases
go test ./... -coverprofile cover.out
? sigs.k8s.io/kubebuilder-declarative-pattern/examples/guestbook-operator [no test files]
? sigs.k8s.io/kubebuilder-declarative-pattern/examples/guestbook-operator/api/v1alpha1 [no test files]
ok sigs.k8s.io/kubebuilder-declarative-pattern/examples/guestbook-operator/controllers 0.181s coverage: 20.0% of statements
docker build . -t gcr.io/willbeason-nomos-test/kdb:latest
Sending build context to Docker daemon 39.24MB
Step 1/21 : FROM ubuntu:latest as kubectl
---> bb0eaf4eee00
Step 2/21 : RUN apt-get update
---> Using cache
---> d7d0a5048503
Step 3/21 : RUN apt-get install -y curl
---> Using cache
---> 5f47dfd6b965
Step 4/21 : RUN curl -fsSL https://dl.k8s.io/release/v1.13.4/bin/linux/amd64/kubectl > /usr/bin/kubectl
---> Using cache
---> 4b95d98fc39d
Step 5/21 : RUN chmod a+rx /usr/bin/kubectl
---> Using cache
---> 0d8def1519e4
Step 6/21 : FROM golang:1.13 as builder
---> d6f3656320fe
Step 7/21 : WORKDIR /go/src/guestbook-operator
---> Using cache
---> d99ed36c50a0
Step 8/21 : COPY go.mod go.mod
---> Using cache
---> 3e39c0c5c721
Step 9/21 : COPY go.sum go.sum
---> Using cache
---> dec5322c8b62
Step 10/21 : RUN go mod download
---> Running in e78b64a2a1d5
go: sigs.k8s.io/kubebuilder-declarative-pattern@v0.0.0: parsing /kubebuilder-declarative-pattern/go.mod: open /kubebuilder-declarative-pattern/go.mod: no such file or directory
The command '/bin/sh -c go mod download' returned a non-zero code: 1
make: *** [Makefile:68: docker-build] Error 1
make: Leaving directory '/usr/local/google/home/willbeason/kubebuilder-declarative-pattern/examples/guestbook-operator'
panic: error execing command "make -C ../examples/guestbook-operator docker-build docker-push deploy": exit status 2
goroutine 1 [running]:
main.mustExec(...)
/usr/local/google/home/willbeason/kubebuilder-declarative-pattern/hack/smoketest.go:91
main.(*CommonAddonTest).InstallOperators(0xc000425c00)
/usr/local/google/home/willbeason/kubebuilder-declarative-pattern/hack/smoketest.go:539 +0x12c
main.main()
/usr/local/google/home/willbeason/kubebuilder-declarative-pattern/hack/smoketest.go:145 +0x4b6
exit status 2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment