Repository navigation
Commit 8dab644
committed
fix(cdi): stop make update from overwriting the first-party CDI object
templates/cdi-cr.yaml is ours. Against upstream's bare CDI object it
adds Helm templating for cloneStrategyOverride, uploadProxyURL and the
worker-pod podResourceRequirements, the ExpandDisks feature gate, a
CriticalAddonsOnly toleration, and the two RBAC documents that let a
tenant clone from the golden-image namespace. Every one of those
arrived by hand, so `wget -O templates/cdi-cr.yaml` was not refreshing
a vendored file, it was overwriting a first-party one -- the same loss
as the `rm -rf templates` this recipe stopped doing, arriving through
the fetch instead of the wipe.
What replaces it: the release the object is derived from is pinned
rather than resolved from GitHub's releases/latest redirect, and
`update` fetches it only to confirm the bytes still hash to a measured
sha256. Nothing is written under templates/. The next CDI bump fails
that check, which is the point -- upstream moving its own defaults is
when the local copy needs a human to reconcile it, not an overwrite.
The download survives a mismatch, because reconciling one starts by
reading it.
RELEASE is v1.66.1, which is what the operator manifest carries on
main. ../kubevirt-cdi-operator pins nothing of its own: its recipe
vendors whatever releases/latest resolved to the last time someone ran
it, so the release the platform deploys can move without this file
noticing. That is why this line is pointed at it by hand rather than
derived, and why neither file reports the two having drifted.
The difference from upstream is stated against v1.66.1 rather than as
a standing fact: v1.64.0 enabled WebhookPvcRendering, which this
object never carried and which v1.66.1 dropped again, so it ran both
ways at one release and one way at the next. The comment says to
re-derive it at each bump for that reason.
The `test:` target this package needed arrived separately, so what it
gains here is the `.PHONY` line that came without: hack/package.mk
declares only the targets it defines itself, so a file or directory
named test or update beside this Makefile would otherwise make that
target up to date and skip the recipe in silence. The suite pins the
clone-strategy override, the ExpandDisks gate, the toleration and the
clone RBAC, and renders the upload-proxy Ingress and TLSRoute, each
under the gateway setting that selects it.
Assisted-by: LLM
Signed-off-by: Aleksei Sviridkin <[email protected]>1 parent 653e6fd commit 8dab644
3 files changed
Lines changed: 141 additions & 7 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | 3 | | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
4 | 23 | | |
5 | 24 | | |
6 | 25 | | |
7 | 26 | | |
8 | 27 | | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
9 | 33 | | |
10 | 34 | | |
11 | 35 | | |
12 | | - | |
13 | | - | |
14 | | - | |
15 | | - | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
16 | 55 | | |
17 | | - | |
18 | | - | |
19 | | - | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
0 commit comments