i've been deploying this mainly for prometheus metrics and it's working great. i still have to test log ingestion. i'll need help with fixing the included grafana dashboards!
i've been deploying this mainly for prometheus metrics and it's working great. i still have to test log ingestion. i'll need help with fixing the included grafana dashboards!
set instance label as hostname, now it's docker's internal ip address
fix included grafana dashboards
node_name was set statically on node-exporter and missing from alloy
TODOs:
- [ ] update documentation
- [ ] implement metrics on recipes
- [ ] set `instance` label as hostname, now it's docker's internal ip address
- [ ] fix included grafana dashboards
- [ ] `node_name` was set statically on `node-exporter` and missing from `alloy`
grafana-stacks-dashboard.json hardcodes the cadvisor.monitoring subdomain a lot to filter by instance, removing it from the dashboard makes the graphs i tried work again, but it breaks filtering by instance
- [ ] `grafana-stacks-dashboard.json` hardcodes the `cadvisor.monitoring` subdomain a lot to filter by instance, removing it from the dashboard makes the graphs i tried work again, but it breaks filtering by instance
i checked with @p4u1 today. this is what we found out:
> set instance label as hostname, now it's docker's internal ip address
in our test today this was the app domain instead
also we figured the containerd socket path needs to be included in the volumes section of the alloy service:
```
volumes:
# ...
- /run/containerd/containerd.sock:/run/containerd/containerd.sock:ro
```
otherwise no containers/services are found.
thanks @dede ! on an alpine 3.21 server this socket seems to be located at /var/run/docker/containerd/containerd.sock while in ubuntu server 24.04 it's at /var/run/containerd/containerd.sock, maybe the location changes by distribution? or they're not the same socket?
thanks @dede ! on an alpine 3.21 server this socket seems to be located at `/var/run/docker/containerd/containerd.sock` while in ubuntu server 24.04 it's at `/var/run/containerd/containerd.sock`, maybe the location changes by distribution? or they're not the same socket?
i could do something like this i think:
```yaml
volumes:
- "${CONTAINERD_SOCKET:-/var/run/containerd/containerd.sock}:/var/run/containerd/containerd.sock:ro"
```
Added an optional scrape_auth secret for authenticating scrapes of
containers that opt in via prometheus.io/auth labels, no longer
reusing the basic_auth secret meant for Prometheus/Loki writes.
Made usernames for both write endpoints and authenticated scraping
configurable in .env.
prometheus.exporter.cadvisor.docker.targets already reports resource
metrics for every container on the host. The unfiltered discovery just
added targets with internal overlay IPs, most of which failed to
scrape anything useful.
Replace node_meta-based joins with label_replace() of the instance
label, so old (pull-model) and new (Alloy push) series for the same
host render as one continuous series. Each rewritten query has a TODO
noting the simpler form to use once old data ages out of retention.
Swarm service discovery misses dnsrr-mode services like traefik; switch
to swarm task discovery, scoped to this host, with a stable instance
label across redeploys and a default port when none is labeled.
Created a PR for Traefik to add metric discovery labels. Will work on updating the README and short migration guide for the release notes this week. Almost ready!
Created a [PR for Traefik](https://git.coopcloud.tech/coop-cloud/traefik/pulls/132) to add metric discovery labels. Will work on updating the README and short migration guide for the release notes this week. Almost ready!
I think all open todos are resolved. Also updated the readme and added a migration guide to the release notes.
Anyone up for testing?
TODO: reset the CONFIG_ALLOY_VERSION back to v1 before merging
This still needs to be done before merging. And probably a squash commit for merging; don't think we need this whole kinda messy history?
I think all open todos are resolved. Also updated the readme and added a migration guide to the release notes.
Anyone up for testing?
> TODO: reset the `CONFIG_ALLOY_VERSION` back to `v1` before merging
This still needs to be done before merging. And probably a squash commit for merging; don't think we need this whole kinda messy history?
dannygroenewegen
requested review from monitoring-ng-maintainers 2026-08-17 14:21:08 +00:00
dannygroenewegen
marked the pull request as ready for review 2026-08-17 14:22:11 +00:00
didn't work for me, needed to explicitly set the env as the nested replacement didn't work.
From docker service inspect: traefik.http.routers.monitoring_kolli_cloud-grafana.rule=Host($DOMAIN)
Hey folks, thanks for the amazing work!
This:
https://git.coopcloud.tech/coop-cloud/monitoring-ng/src/commit/382f6353fc802abbddee19e571a6d2556c65371c/compose.grafana.yml#L42
didn't work for me, needed to explicitly set the env as the nested replacement didn't work.
From docker service inspect:
`traefik.http.routers.monitoring_kolli_cloud-grafana.rule=Host(`$DOMAIN`)`
By default, that folder doesn't exist, resulting in continues errors: 2026-08-21T14:59:53.360890994Z logger=provisioning.dashboard type=file name=default-alert-provider t=2026-08-21T14:59:53.360693215Z level=error msg="failed to walk provisioned dashboards" error="stat /var/lib/grafana/alerts: no such file or directory"
I guess we could also remove this. I've seen your discussion in matrix about it:
https://git.coopcloud.tech/coop-cloud/monitoring-ng/src/commit/02b01e5c236e963ccdcfc422c3c099c6bbf41e8e/grafana-dashboards.yml#L14-L23
By default, that folder doesn't exist, resulting in continues errors:
`2026-08-21T14:59:53.360890994Z logger=provisioning.dashboard type=file name=default-alert-provider t=2026-08-21T14:59:53.360693215Z level=error msg="failed to walk provisioned dashboards" error="stat /var/lib/grafana/alerts: no such file or directory"`
And from my knowledge its never used anywhere anyway. Looks like @p4u1 added it 2 years ago, maybe he knows more? https://git.coopcloud.tech/coop-cloud/monitoring-ng/commit/0352a393de77d58c8462a69cf805f5cc7e3c8156#diff-338a7a8dc1f47ef86aa7fe511610bc988be2e70c
By default, that folder doesn't exist, resulting in continues errors: 2026-08-21T14:59:53.360890994Z logger=provisioning.dashboard type=file name=default-alert-provider t=2026-08-21T14:59:53.360693215Z level=error msg="failed to walk provisioned dashboards" error="stat /var/lib/grafana/alerts: no such file or directory"
> I guess we could also remove this. I've seen your discussion in matrix about it:
>
> https://git.coopcloud.tech/coop-cloud/monitoring-ng/src/commit/02b01e5c236e963ccdcfc422c3c099c6bbf41e8e/grafana-dashboards.yml#L14-L23
>
> By default, that folder doesn't exist, resulting in continues errors:
> `2026-08-21T14:59:53.360890994Z logger=provisioning.dashboard type=file name=default-alert-provider t=2026-08-21T14:59:53.360693215Z level=error msg="failed to walk provisioned dashboards" error="stat /var/lib/grafana/alerts: no such file or directory"`
>
> And from my knowledge its never used anywhere anyway. Looks like @p4u1 added it 2 years ago, maybe he knows more? https://git.coopcloud.tech/coop-cloud/monitoring-ng/commit/0352a393de77d58c8462a69cf805f5cc7e3c8156#diff-338a7a8dc1f47ef86aa7fe511610bc988be2e70c
Yeah, this can be removed. Alerts are now configured like this: https://git.coopcloud.tech/coop-cloud/monitoring-ng/src/commit/02b01e5c236e963ccdcfc422c3c099c6bbf41e8e/alerts/node.yml.tmpl
You are not authorized to merge this pull request.
This pull request can be merged automatically.
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
closes #20
doing good progress but abyaya.la doesn't support two levels of subdomains yet so i can't keep testing! will continue soon
TODO: reset the
CONFIG_ALLOY_VERSIONback tov1before mergingThanks for this work! I also hope to do some testing with this soon.
i've been deploying this mainly for prometheus metrics and it's working great. i still have to test log ingestion. i'll need help with fixing the included grafana dashboards!
TODOs:
instancelabel as hostname, now it's docker's internal ip addressnode_namewas set statically onnode-exporterand missing fromalloygrafana-stacks-dashboard.jsonhardcodes thecadvisor.monitoringsubdomain a lot to filter by instance, removing it from the dashboard makes the graphs i tried work again, but it breaks filtering by instancei checked with @p4u1 today. this is what we found out:
in our test today this was the app domain instead
also we figured the containerd socket path needs to be included in the volumes section of the alloy service:
otherwise no containers/services are found.
thanks @dede ! on an alpine 3.21 server this socket seems to be located at
/var/run/docker/containerd/containerd.sockwhile in ubuntu server 24.04 it's at/var/run/containerd/containerd.sock, maybe the location changes by distribution? or they're not the same socket?i could do something like this i think:
ccff913b5dto0f989c4567Created a PR for Traefik to add metric discovery labels. Will work on updating the README and short migration guide for the release notes this week. Almost ready!
I think all open todos are resolved. Also updated the readme and added a migration guide to the release notes.
Anyone up for testing?
This still needs to be done before merging. And probably a squash commit for merging; don't think we need this whole kinda messy history?
did a test deploy and looks like alloy works!
did a test deploy and looks like alloy works!
new readme is a lot more clean!
Hey folks, thanks for the amazing work!
This:
didn't work for me, needed to explicitly set the env as the nested replacement didn't work.
From docker service inspect:
traefik.http.routers.monitoring_kolli_cloud-grafana.rule=Host($DOMAIN)I guess we could also remove this. I've seen your discussion in matrix about it:
By default, that folder doesn't exist, resulting in continues errors:
2026-08-21T14:59:53.360890994Z logger=provisioning.dashboard type=file name=default-alert-provider t=2026-08-21T14:59:53.360693215Z level=error msg="failed to walk provisioned dashboards" error="stat /var/lib/grafana/alerts: no such file or directory"And from my knowledge its never used anywhere anyway. Looks like @p4u1 added it 2 years ago, maybe he knows more?
0352a393de (diff-338a7a8dc1f47ef86aa7fe511610bc988be2e70c)Yeah, this can be removed. Alerts are now configured like this:
02b01e5c23/alerts/node.yml.tmplView command line instructions
Checkout
From your project repository, check out a new branch and test the changes.