Skip to content

feat(alloy): set default resource requests - #92

Merged
jtslear merged 1 commit into
mainfrom
skarbek/alloy-default-resource-requests
Oct 20, 2026
Merged

jtslear merged 1 commit into
mainfrom
skarbek/alloy-default-resource-requests

Conversation

@jtslear

@jtslear jtslear commented Oct 16, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

Set default resource requests for the Alloy container: cpu: 50m, memory: 128Mi. No limits.

Review of coder/dogfood#702 (v0.8.0 bump) asked for dogfood settings to become chart defaults. Source: https://github.com/coder/dogfood/pull/702#pullrequestreview-5547941289

Dogfood sets requests 200m/1Gi and limits 200m/2Gi. Those values are sized for the dogfood clusters and are not a safe default. This chart sets no resources for any component, so this PR only adds a floor.

Why

Without requests, the scheduler reserves nothing for the collector and the node evicts it first under memory pressure (CRF-2 in that review).

Decision for the reviewer

The values are a judgement call. Both are below real usage on purpose: they only give scheduling weight.

  • Idle usage on the kind cluster is about 150Mi memory and 25m CPU with 20 pods.
  • No limits, because a limit could throttle or OOM-kill the collector on large clusters.

Test

Kind cluster used for testing. Baseline is main: container resources: {}.

result
50m/128Mi (this PR) pod Running, QoS Burstable, resources.requests = 50m/128Mi
Prometheus up{container="alloy"} = 1

Notes

  • compiled/resources.yaml and README.md regenerated with make build and make readme.

The Alloy container has no resource requests by default. The scheduler
reserves nothing for it, and the node evicts it first under memory
pressure.

Set small CPU and memory requests. Set no limits: usage grows with the
number of scrape targets, and a limit could throttle or OOM-kill the
collector on large clusters. Operators can override
alloy.alloy.resources.
@jtslear
jtslear force-pushed the skarbek/alloy-default-resource-requests branch from 9be30ad to 64851f0 Compare October 16, 2026 15:04
@jtslear
jtslear marked this pull request as ready for review October 16, 2026 15:32
@jtslear
jtslear requested a review from dannykopping as a code owner October 16, 2026 15:32
@jtslear
jtslear merged commit be16d32 into main Oct 20, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants