Commit ef759bd
fix: align mongo/k8s/0.2 size schema with TF and make service host-anti-affinity optional
Two module-schema bugs that caused false-positive pre-flight validation
errors (raptor create release) while the platform/Deployer accepts the
specs fine.
mongo/k8s/0.2: the size schema declared `cpu`/`memory` (required), but the
v0.2 Terraform (facets-iac .../1_input_instance/mongodb/main.tf) reads
`cpu_requests`/`memory_requests` behind a `contains(keys, "cpu_requests")`
guard. The `cpu`/`memory` naming only belongs to the 0.3 TF. As a result a
blueprint following the 0.2 schema would silently get NO resource requests,
and a correct blueprint (using cpu_requests/memory_requests, as prod does)
fails validation with "spec.size.memory required field is missing". Rename
the request fields to cpu_requests/memory_requests so the schema matches the
v0.2 module and real usage; limit fields and their x-ui-compare refs updated
to match.
service/deployment/0.1: `enable_host_anti_affinity` was in the spec
`required` list with no default, but the shared app-chart helm template
guards it with `hasKey` and treats absence as "no anti-affinity". The field
is behaviorally optional, so requiring it rejects valid specs (e.g.
service/control-plane-ui). Remove it from `required` (kept in properties and
x-ui-order). Follows the precedent of #520 (health_checks made optional).
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>1 parent 212dd21 commit ef759bd
2 files changed
Lines changed: 8 additions & 9 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
42 | 42 | | |
43 | 43 | | |
44 | 44 | | |
45 | | - | |
| 45 | + | |
46 | 46 | | |
47 | 47 | | |
48 | 48 | | |
| |||
54 | 54 | | |
55 | 55 | | |
56 | 56 | | |
57 | | - | |
| 57 | + | |
58 | 58 | | |
59 | 59 | | |
60 | 60 | | |
| |||
73 | 73 | | |
74 | 74 | | |
75 | 75 | | |
76 | | - | |
| 76 | + | |
77 | 77 | | |
78 | 78 | | |
79 | 79 | | |
| |||
85 | 85 | | |
86 | 86 | | |
87 | 87 | | |
88 | | - | |
| 88 | + | |
89 | 89 | | |
90 | 90 | | |
91 | 91 | | |
| |||
100 | 100 | | |
101 | 101 | | |
102 | 102 | | |
103 | | - | |
104 | | - | |
| 103 | + | |
| 104 | + | |
105 | 105 | | |
106 | 106 | | |
107 | 107 | | |
| |||
161 | 161 | | |
162 | 162 | | |
163 | 163 | | |
164 | | - | |
165 | | - | |
| 164 | + | |
| 165 | + | |
166 | 166 | | |
167 | 167 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1757 | 1757 | | |
1758 | 1758 | | |
1759 | 1759 | | |
1760 | | - | |
1761 | 1760 | | |
1762 | 1761 | | |
1763 | 1762 | | |
| |||
0 commit comments