【发布时间】:2022-01-16 06:15:38
【问题描述】:
我尝试使用 helm chart 在 AKS 中设置弹性搜索集群,但由于 log4j 漏洞,我想将其设置为选项
-Dlog4j2.formatMsgNoLookups
设置为
true
。当我在 helm 命令中传递参数时,出现未知标志错误。
参考:
https://artifacthub.io/packages/helm/elastic/elasticsearch/6.8.16
helm upgrade elasticsearch elasticsearch --set imageTag=6.8.16 esJavaOpts "-Dlog4j2.formatMsgNoLookups=true"
Error: unknown shorthand flag: 'D' in -Dlog4j2.formatMsgNoLookups=true
我也尝试在
values.yaml
文件中添加以下内容
esConfig: {}
# elasticsearch.yml: |
# key:
# nestedkey: value
log4j2.properties: |
-Dlog4j2.formatMsgNoLookups = true
但这些值并未添加到
/usr/share/elasticsearch/config/jvm.options
、
/usr/share/elasticsearch/config/log4j2.properties
或环境变量中。