How to solve helm error: "did not find expected '-' indicator"?

How to solve helm error: "did not find expected '-' indicator"?

我正在尝试使用 helm 部署某个节点,但在安装之前,我想确保模板是正确的,因此我正在尝试 运行 helm template . --debug 并且显示了一个错误:

Error: YAML parse error on generic-node/templates/rosetta.yaml: error converting YAML to JSON: yaml: line 39: did not find expected '-' indicator
helm.go:84: [debug] error converting YAML to JSON: yaml: line 39: did not find expected '-' indicator
`
The section with the error is shown thus:
    - name: ***
      valueFrom:
        secretKeyRef:
          name: "generic-node-devnet-bp-key"
          key: password
    - name: ****
      valueFrom:
        secretKeyRef:
          name: "generic-node-devnet-bp-key"
          key: password

****的关键是第39行,我不知道为什么它被标记了,有人可以帮忙吗?

谢谢

您似乎遇到了行中空格过多的问题。网上有 YAML 检查器,以下 link 可以帮助您验证 YAML。 http://www.yamllint.com/