【问题标题】:InfluxDB2 on Kubernetes not using existing admin password/token secretInfluxDB2 on Kubernetes not using existing admin password/token secret
【发布时间】:2022-12-26 16:39:50
【问题描述】:

I'm installing InfluxDB2 on a Kubernetes cluster (AWS EKS) and in the helm chart I specify an existing secret name "influxdb-auth" for admin user credentials. When I try to login to the web admin interface, it does not accept the password or token from that secret. If I don't specify an existing secret, it automatically creates a secret "influxdb2-auth" and I can retrieve and use the password successfully, but it will not use the existing secret. Also when I specify the existing secret "influxdb-auth" it does not create a secret "influxdb2-auth" so I can't retrieve the password it has generated. I have tried naming the existing secret "influxdb2-auth" but that also did not work. Any ideas on what the problem might be?

Section from values.yaml:

## Create default user through docker entrypoint
## Defaults indicated below
##
adminUser:
  organization: "test"
  bucket: "default"
  user: "admin"
  retention_policy: "0s"
  ## Leave empty to generate a random password and token.
  ## Or fill any of these values to use fixed values.
  password: ""
  token: ""

  ## The password and token are obtained from an existing secret. The expected
  ## keys are `admin-password` and `admin-token`.
  ## If set, the password and token values above are ignored.
  existingSecret: influxdb-auth

【问题讨论】:

    标签: kubernetes influxdb


    【解决方案1】:

    To anyone here coming here from the future. Make sure you run:

    echo $(kubectl get secret influxdb-influxdb2-auth -o "jsonpath={.data['admin-password']}" --namespace monitoring | base64 --decode)
    

    afterfirstinstallation. First time influxdb2 starts it will setup task, subsequent helm install/upgrade seem to save new password in the secret which isn't on the file system.

    I had to delete content of PVC for influxdb and rerun installation.

    【讨论】:

      猜你喜欢
      • 2012-10-14
      • 1970-01-01
      • 2023-03-23
      • 1970-01-01
      • 2017-06-07
      • 1970-01-01
      • 2022-12-01
      • 2015-05-08
      • 2021-12-30
      相关资源
      最近更新 更多