Open sed-i opened 1 day ago
This is a Grafana Agent issue. When we build the Loki config, we currently do:
...
if self._loki_consumer.loki_endpoints:
configs.append(
{
"name": "push_api_server",
"clients": self._loki_endpoints_with_tls(),
"scrape_configs": [
...
The endpoints from Grafana Cloud integrator are coming from self._loki_endpoints_with_tls()
, meaning we won't add them to the configuration if there are no endpoints coming from _loki_consumer
(which is the case if you don't relate Grafana Agent to Loki).
Bug Description
The grafana-agent.yaml file that grafana agent renders, with the help of the grafana_cloud_integrator lib, ends up with an empty "loki" section, even though loki_url was set as a config option in the integrator charm.
To Reproduce
Deploy the following bundle. The
loki
section injuju ssh --container agent ga/0 cat /etc/grafana-agent.yaml
is empty.Environment
Relevant log output
Additional context
No response