"make keys secret" 因错误而失败 "make: *** No rule to make target `keys'. Stop."

"make keys secret" failing with error "make: *** No rule to make target `keys'. Stop."

我正在关注此文档 https://kubernetes.io/docs/concepts/services-networking/connect-applications-service/#securing-the-service 并尝试了以下命令:

make keys secret KEY=/tmp/nginx.key CERT=/tmp/nginx.crt SECRET=/tmp/secret.json

但失败并出现错误:

make: *** No rule to make target `keys'.  Stop.

有什么建议吗?

这来自 Makefile 上文 link 中的描述。您需要从 makefile 中提取 repo、更改目录和 运行 操作。

keys 下一个动作(根据那个 makefile)

openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout $(KEY) -out $(CERT) -subj "/CN=nginxsvc/O=nginxsvc"

make 命令只是 Makefile 中描述的 运行s 操作(您需要在本地拉取)