Reputation: 8988
I am not sure if the issue is related to promtail (helm chart used) or to helm itself.
I want to update the default host value for loki chart to a local host used on kubernetes, so I tried with this:
helm upgrade --install --namespace loki promtail grafana/promtail --set client.url=http://loki:3100/loki/api/v1/push
And with a custom values.yaml like this:
helm upgrade --install --namespace loki promtail grafana/promtail -f promtail.yaml
But it still uses wrong default url:
level=warn ts=2021-10-08T11:51:59.782636939Z caller=client.go:344 component=client host=loki-gateway msg="error sending batch, will retry" status=-1 error="Post \"http://loki-gateway/loki/api/v1/push\": dial tcp: lookup loki-gateway on 10.43.0.10:53: no such host"
If I inspect the config.yaml its using it doesnt use the internal url I gave during the installation:
root@promtail-69hwg:/# cat /etc/promtail/promtail.yaml
server:
log_level: info
http_listen_port: 3101
client:
url: http://loki-gateway/loki/api/v1/push
Any ideas? or anything I am missing?
Thanks
Upvotes: 1
Views: 1355
Reputation: 2268
I don't think client.url
is a value in the helm chart, but rather one inside a config file that your application is using.
Try setting config.lokiAddress
:
config:
lokiAddress: http://loki-gateway/loki/api/v1/push
It gets templated into the config file I mentioned.
Upvotes: 2