【发布时间】:2017-12-10 04:07:08
【问题描述】:
作为标题,我在 plugin/pkg/scheduler/algorithm/priorities 文件夹中为 Kubernetes 添加了一个新的算法包。它是一个文件夹,里面有一些 Go 源文件,比如 util 文件夹。但是,当运行make 时,我得到了错误:
test/e2e_node/e2e_node.test
cmd/gke-certificates-controller
plugin/pkg/scheduler/algorithm/priorities/test.go:7:2: no buildable Go source files in /home/zhangjian/src/k8s.io/kubernetes/_output/local/go/src/k8s.io/kubernetes/plugin/pkg/scheduler/algorithm/priorities/test
!!! [0703 09:22:46] Call tree:
!!! [0703 09:22:46] 1: /home/zhangjian/src/k8s.io/kubernetes/hack/lib/golang.sh:740 kube::golang::build_binaries_for_platform(...)
!!! [0703 09:22:46] 2: hack/make-rules/build.sh:27 kube::golang::build_binaries(...)
!!! [0703 09:22:46] Call tree:
!!! [0703 09:22:46] 1: hack/make-rules/build.sh:27 kube::golang::build_binaries(...)
!!! [0703 09:22:46] Call tree:
!!! [0703 09:22:46] 1: hack/make-rules/build.sh:27 kube::golang::build_binaries(...)
make: *** [all] Error 1
它们确实是 Go 文件,我不知道错误的原因。还是我错过了什么?
而我只是想在priority中加入我自己的算法包(不是第三个库,比如exapmle.com/xxx/xxx),那么步骤是什么?
我参考了community/contributors/devel/godep.md并尝试了go build ./...、./hack/godep-restore.sh、./hack/godep-save.sh命令,但还是不行。
【问题讨论】:
标签: go kubernetes