Self-host Grafana Alloy with Levelrail

A telemetry collector that scrapes metrics and ships them to Prometheus-compatible, Loki or Tempo backends. This starts with a small pipeline that scrapes its own metrics and logs them; edit the config to forward data elsewhere.

  • Authorgrafana
  • LicenceApache-2.0
  • Memory256 MiB
  • Services1

How to self-host Grafana Alloy

  1. Pull the images

    One image is pulled on your server.

    Show images
    • grafana/alloy:v1.21.3
  2. Create the app

    One service starts in a single Compose app, with 1 named volume mount for your data, on port 12345.

  3. Fill in the secrets

    You do not have to fill in anything.

  4. Open it

    Without a domain the app gets an sslip.io address; add --domain SERVICE=HOST to use your own.

After the first start

  • Open the page to see the component graph, then replace the config with your own pipeline and redeploy.

Grafana Alloy requirements

Memory
About 256 MiB
Architectures
amd64 unknown, arm64 unknown
Ports
12345
Domain
Optional, an sslip.io address is used without one
Settings
none to fill in
License
Apache-2.0, permissive license
  • Listed. It is in the catalog but not verified. Back up the data volume before changing an image tag.

Install Levelrail first

On a server with Levelrail running, run the command above, or open the dashboard: Apps, New app, Browse templates, then Grafana Alloy. New to Levelrail? Install it on a fresh VPS first.

docker pull ghcr.io/glincker/levelrail:latest

Then levelrail-cli login --device. See Getting started and the Grafana Alloy docs page.

Deploy Grafana Alloy your way

Every format below deploys the same pinned images. Pick the one that fits how you work.

Deploy Grafana Alloy from the CLI

levelrail-cli templates deploy grafana-alloy --name my-grafana-alloy

Deploy Grafana Alloy with the API

Create a token in the dashboard first. This one-click route deploys it as a trial app you can keep or remove.

curl -X POST -H "Authorization: Bearer $TOKEN" \
  https://levelrail.example.com/api/v1/service-templates/grafana-alloy/deploy

Grafana Alloy configuration

Grafana Alloy services

ServiceImagePortsVolumes
alloy grafana/alloy:v1.21.3 12345 alloy_data -> /var/lib/alloy/data

Grafana Alloy environment variables

The catalog lists no environment variables for this template.

Ports and volumes

Ports
12345
Volumes
1 named mount: alloy_data -> /var/lib/alloy/data

Grafana Alloy FAQ

How much memory does Grafana Alloy need?

The catalog lists about 256 MiB of memory for Grafana Alloy.

Does Grafana Alloy run on arm64?

For Grafana Alloy, arm64 support is not confirmed; amd64 is unknown.

What licence is Grafana Alloy under?

Grafana Alloy is licensed under Apache-2.0, which is permissive, with few conditions on reuse.

Does Grafana Alloy need configuration before it starts?

No. The template fills in its own defaults.

Which ports does Grafana Alloy use?

Grafana Alloy listens on port 12345 inside the stack.

Where does Grafana Alloy keep its data?

In a named volume: alloy_data mounted at /var/lib/alloy/data.

Can I deploy Grafana Alloy on Dokploy or Dokku?

The services and pinned images on this page can be run on any Docker host. The public Dokploy templates list we compared does not have an entry with the same id for Grafana Alloy, so on Dokploy you would use a Docker Compose application with the file from this page. Dokku deploys container images with its own commands, so the pinned image grafana/alloy:v1.21.3 is what you deploy there.

levelrail-cli templates deploy grafana-alloy --name my-grafana-alloy