谁能解释<CERTIFICATE_DATA_REDACTED>是什么意思?

时间:2019-07-14 22:44:28

标签: kubernetes elasticsearch-opendistro

我正在尝试设置ElasticSearch OpenDistro,但无法理解链接中的<CERTIFICATE_DATA_REDACTED>

https://github.com/opendistro-for-elasticsearch/community/blob/master/open-distro-elasticsearch-kubernetes/elasticsearch/35-es-bootstrap-secrets.yml

我应该如何使用此Yaml文件?我是否需要将base64编码值放在这里,然后替换kubectl apply -f secrets.yaml或什么?

有人可以提供与此相关的任何参考链接吗?

kind: Secret
metadata:
  name: elasticsearch-tls-data
  namespace: elasticsearch
type: Opaque
stringData:
  elk-crt.pem: |-
    <CERTIFICATE_DATA_REDACTED>
  elk-key.pem: |-
    <CERTIFICATE_DATA_REDACTED>
  elk-root-ca.pem: |-
    <CERTIFICATE_DATA_REDACTED>
  admin-crt.pem: |-
    <CERTIFICATE_DATA_REDACTED>
  admin-key.pem: |-
    <CERTIFICATE_DATA_REDACTED>
  admin-root-ca.pem: |-
    <CERTIFICATE_DATA_REDACTED> ````

1 个答案:

答案 0 :(得分:1)

我以前没有使用过此配置,但我认为您应该做的是与Kibana一起elk-crt.pem, elk-key.pem, elk-root-ca.pem, admin-crt.pem, admin-key.pem, admin-root-ca.pem创建自己的证书(如果要使用它),然后仅使用原始值创建Secret,

请阅读:

For certain scenarios, you may wish to use the stringData field instead. This field allows you to put a non-base64 encoded string directly into the Secret, and the string will be encoded for you when the Secret is created or updated.

https://kubernetes.io/docs/concepts/configuration/secret/