After #87 merged and rolled out, the config-sync sidecar OOMKilled (exit 137) at the 64Mi limit and crashlooped — it never completed a sync, so config is still not auto-deploying.
Root cause
The homeassistant repo's .git is ~1.1 GB, dominated by a 1 GB backup tar committed into history (backups/home-assistant…tar). On first git fetch, git auto-gc tried to repack that entire pack inside the 64Mi sidecar → instant OOM (it died ~7s after start). Measured peak RSS for the actual fetch/checkout of config blobs is ~8 MB, so the sync itself is cheap — it was the repack that blew up.
Fix
Disable gc.auto in config-sync.sh (+ cap pack.windowMemory, pack.deltaCacheSize, core.deltaBaseCacheLimit) so the sidecar never repacks and only touches small config blobs.
Raise the sidecar memory limit 64Mi → 256Mi for index-pack headroom on the first fetch.
Follow-up (separate, not in this PR)
Purge the 1 GB backup tar from the homeassistant repo history (git-filter-repo/BFG) and .gitignorebackups/. It bloats every clone and the config PVC, and is the underlying reason git is heavy here.
Validation
sh -n clean, kubectl kustomize builds. Once merged, Flux rolls a new pod; I'll confirm the sidecar reaches steady state, syncs /config to main, and that homeassistant.reload_all makes the new add_notification_to_queue (audience/title/data) live.
## Problem
After #87 merged and rolled out, the `config-sync` sidecar **OOMKilled (exit 137) at the 64Mi limit and crashlooped** — it never completed a sync, so config is still not auto-deploying.
## Root cause
The homeassistant repo's `.git` is **~1.1 GB**, dominated by a **1 GB backup tar committed into history** (`backups/home-assistant…tar`). On first `git fetch`, git **auto-gc** tried to repack that entire pack inside the 64Mi sidecar → instant OOM (it died ~7s after start). Measured peak RSS for the actual fetch/checkout of config blobs is ~8 MB, so the sync itself is cheap — it was the repack that blew up.
## Fix
- **Disable `gc.auto`** in `config-sync.sh` (+ cap `pack.windowMemory`, `pack.deltaCacheSize`, `core.deltaBaseCacheLimit`) so the sidecar never repacks and only touches small config blobs.
- Raise the sidecar memory limit **64Mi → 256Mi** for index-pack headroom on the first fetch.
## Follow-up (separate, not in this PR)
Purge the 1 GB backup tar from the homeassistant repo history (git-filter-repo/BFG) and `.gitignore` `backups/`. It bloats every clone and the config PVC, and is the underlying reason git is heavy here.
## Validation
`sh -n` clean, `kubectl kustomize` builds. Once merged, Flux rolls a new pod; I'll confirm the sidecar reaches steady state, syncs `/config` to `main`, and that `homeassistant.reload_all` makes the new `add_notification_to_queue` (audience/title/data) live.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
The config-sync sidecar OOMKilled (exit 137) at the 64Mi limit and crashlooped,
so it never synced. Root cause: this repo's .git is ~1.1 GB (a 1 GB backup tar
lives in history), and git auto-gc tried to repack that whole pack inside the
tiny sidecar on first fetch.
- Disable gc.auto in the sync script and cap pack window / delta caches, so
fetch/checkout only ever touch the small config blobs and never repack.
- Raise the sidecar memory limit 64Mi -> 256Mi for index-pack headroom on the
first fetch.
Follow-up (not here): purge the 1 GB backup tar from the homeassistant repo
history and .gitignore backups/ — it bloats every clone and the config PVC.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01GgbyKgrN1yYWrkAA32rJE5
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.
Problem
After #87 merged and rolled out, the
config-syncsidecar OOMKilled (exit 137) at the 64Mi limit and crashlooped — it never completed a sync, so config is still not auto-deploying.Root cause
The homeassistant repo's
.gitis ~1.1 GB, dominated by a 1 GB backup tar committed into history (backups/home-assistant…tar). On firstgit fetch, git auto-gc tried to repack that entire pack inside the 64Mi sidecar → instant OOM (it died ~7s after start). Measured peak RSS for the actual fetch/checkout of config blobs is ~8 MB, so the sync itself is cheap — it was the repack that blew up.Fix
gc.autoinconfig-sync.sh(+ cappack.windowMemory,pack.deltaCacheSize,core.deltaBaseCacheLimit) so the sidecar never repacks and only touches small config blobs.Follow-up (separate, not in this PR)
Purge the 1 GB backup tar from the homeassistant repo history (git-filter-repo/BFG) and
.gitignorebackups/. It bloats every clone and the config PVC, and is the underlying reason git is heavy here.Validation
sh -nclean,kubectl kustomizebuilds. Once merged, Flux rolls a new pod; I'll confirm the sidecar reaches steady state, syncs/configtomain, and thathomeassistant.reload_allmakes the newadd_notification_to_queue(audience/title/data) live.🤖 Generated with Claude Code