【问题标题】:Error parsing ElasticSearch helm chart when adding lifecycle添加生命周期时解析 ElasticSearch helm chart 时出错
【发布时间】:2023-02-24 07:06:36
【问题描述】:

我在 Kubernetes 集群上部署了一个 camunda/camunda 平台图表。我正在尝试为索引设置生命周期策略,但在执行升级命令时遇到问题:

helm upgrade -f camunda-values.yaml camunda camunda/camunda-platform

我收到以下错误:

 Error: UPGRADE FAILED: parse error at (camunda-platform/charts/identity/templates/_helpers.tpl:184): "-"

以下是 camunda-values.yaml 文件(注意:为清楚起见,我省略了 curl 以设置模板):

elasticsearch:
    lifecycle:
        postStart:
            exec:
                command:
                    - bash
                    - -c
                    - |
                      #!/bin/bash
                      # Configure life cycle management
                      ES_URL=http://localhost:9200
                      while [[ "$(curl -s -o /dev/null -w '%{http_code}\n' $ES_URL)" != "200" ]]; do sleep 1; done
                      # Add a policy with 30 days delete action
                      TEMPLATE_NAME=index_del_policy
                      curl -X PUT "$ES_URL/_ilm/policy/$TEMPLATE_NAME" -H 'Content-Type: application/json' -d '{"policy": { "phases": { "delete": { "min_age": "30d", "actions": { "delete": {} } } } } } '

问题是,当我只尝试升级 elasticsearch 时,为什么会收到 identity 的错误?

【问题讨论】:

标签: elasticsearch kubernetes-helm


【解决方案1】:

Helm 版本不兼容。我使用的是版本3.5.4。一旦我升级到3.11.1,升级就会正确运行。 3.11.0 也可以。

【讨论】:

    猜你喜欢
    • 2016-12-20
    • 2023-04-11
    • 2020-01-24
    • 2020-11-30
    • 1970-01-01
    • 2017-11-14
    • 2014-11-19
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多