diff --git a/Makefile b/Makefile index ea2a30ab7..b08fc43e6 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,4 @@ -.PHONY: all deps static clean realclean client-lint client-test client-sync backend frontend shell lint ui-upload +.PHONY: all cri deps static clean realclean client-lint client-test client-sync backend frontend shell lint ui-upload # If you can use Docker without being root, you can `make SUDO= ` SUDO=$(shell docker info >/dev/null 2>&1 || echo "sudo -E") @@ -45,6 +45,16 @@ IMAGE_TAG=$(shell ./tools/image-tag) all: $(SCOPE_EXPORT) +update-cri: + curl https://raw.githubusercontent.com/kubernetes/kubernetes/master/pkg/kubelet/apis/cri/runtime/v1alpha2/api.proto > cri/runtime/api.proto + +protoc-gen-gofast: + @go get -u -v github.com/gogo/protobuf/protoc-gen-gofast + +# Use cri target to download latest cri proto files and regenerate CRI runtime files. +cri: update-cri protoc-gen-gofast + @cd $(GOPATH)/src;protoc --proto_path=$(GOPATH)/src --gofast_out=plugins=grpc:. github.com/weaveworks/scope/cri/runtime/api.proto + docker/weave: curl -L https://github.com/weaveworks/weave/releases/download/v$(WEAVENET_VERSION)/weave -o docker/weave chmod u+x docker/weave