Emit transfer.v1.local unpack_config for containerd_snapshotter #5
+8
−0
Claude / Claude Code Review
completed
Apr 27, 2026 in 5m 16s
Code review found 2 important issues
Found 5 candidates, confirmed 2. See review comments for details.
Details
| Severity | Count |
|---|---|
| 🔴 Important | 2 |
| 🟡 Nit | 0 |
| 🟣 Pre-existing | 0 |
| Severity | File:Line | Issue |
|---|---|---|
| 🔴 Important | roles/container-engine/containerd/templates/config.toml.j2:3 |
imports hardcodes /etc/containerd/conf.d, ignoring containerd_cfg_dir |
| 🔴 Important | roles/container-engine/containerd/templates/config.toml.j2:93-97 |
Hardcoded platform="linux/amd64" regresses arm64/arm hosts |
Annotations
Check failure on line 3 in roles/container-engine/containerd/templates/config.toml.j2
claude / Claude Code Review
imports hardcodes /etc/containerd/conf.d, ignoring containerd_cfg_dir
The new `imports` line hardcodes `/etc/containerd/conf.d/*.toml` while the rest of the template and role uses the configurable `containerd_cfg_dir` (default `/etc/containerd`). If a user overrides `containerd_cfg_dir` (e.g. to `/opt/containerd`), `config.toml` will be written under the override but containerd will still scan the hardcoded `/etc/containerd/conf.d/`, silently dropping their drop-ins. Fix: `imports = ["{{ containerd_cfg_dir }}/conf.d/*.toml"]`.
Check failure on line 97 in roles/container-engine/containerd/templates/config.toml.j2
claude / Claude Code Review
Hardcoded platform="linux/amd64" regresses arm64/arm hosts
The new `unpack_config` block hardcodes `platform = "linux/amd64"`, which regresses arm64/arm hosts: on aarch64 nodes the declared unpack platform won't match the host and containerd will reproduce the very "no unpack platforms defined" failure this PR is meant to fix. Replace with `platform = "linux/{{ image_arch }}"` (or `linux/{{ host_architecture }}`) to stay consistent with how the rest of the codebase handles arch-aware values.
Loading