【问题标题】:Encrypting Secret Data at Rest in Kubernetes AKS?在 Kubernetes AKS 中加密静态秘密数据?
【发布时间】:2019-11-28 21:21:32
【问题描述】:

我无法弄清楚如何更改我的 kube-apiserver。我从 azure AKS 使用的当前版本是 1.13.7。

以下是我需要更改 kubernetes 中的 kube-apiserver 的内容。

kube-apiserver 进程接受一个参数 --encryption-provider-config 来控制 API 数据在 etcd 中的加密方式。

另外,我找不到 kube-apiserver。

Yaml File Formatted

apiVersion: apiserver.config.k8s.io/v1
kind: EncryptionConfiguration
resources:
  - resources:
    - secrets
    providers:
    - identity: {}
    - aesgcm:
        keys:
        - name: key1
          secret: c2VjcmV0IGlzIHNlY3VyZQ==
        - name: key2
          secret: dGhpcyBpcyBwYXNzd29yZA==
    - aescbc:
        keys:
        - name: key1
          secret: c2VjcmV0IGlzIHNlY3VyZQ==
        - name: key2
          secret: dGhpcyBpcyBwYXNzd29yZA==
    - secretbox:
        keys:
        - name: key1
          secret: YWJjZGVmZ2hpamtsbW5vcHFyc3R1dnd4eXoxMjM0NTY=

我已尝试应用此 yaml 文件,但我得到的错误如下。

错误:无法识别“examplesecret.yaml”:种类不匹配 “apiserver.config.k8s.io/v1”版本中的“EncryptionConfiguration”

在 azure 中创建了 aks 集群。使用示例加密 yaml 文件。预计能够创建休息秘密。我得到的结果无法创建。

【问题讨论】:

  • 你找到解决办法了吗?

标签: kubernetes kubectl azure-aks kube-apiserver


【解决方案1】:

Kind: EncryptionConfiguration 只能被 api-server 通过标志 --encryption-provider-config= (ref) 理解;在 AKS 中,无法将该标志传递给 api-server,因为它是一项托管服务。随时在public forum 中请求该功能。

【讨论】:

    猜你喜欢
    • 2021-11-29
    • 2016-02-17
    • 2020-05-10
    • 1970-01-01
    • 1970-01-01
    • 2021-10-06
    • 2016-11-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多