helm "values don't meet the specifications of the schema" in CI
Helm validates values against the chart's values.schema.json before rendering. When a value is missing, the wrong type, or not allowed, it fails with "values don't meet the specifications of the schema(s)" and lists each violation.
What this error means
helm template, install, or lint fails with "values don't meet the specifications of the schema(s) in the following chart(s):" followed by per-field messages.
Error: values don't meet the specifications of the schema(s) in the following chart(s):
mychart:
- replicaCount: Invalid type. Expected: integer, given: string
- image: image is requiredCommon causes
A value of the wrong type
A field like replicaCount: "2" is a string where the schema requires an integer.
A missing required value or a disallowed extra key
The schema marks a value required (or forbids extras via additionalProperties), and the values file does not comply.
How to fix it
Correct values to match the schema
- Read each "- field: reason" line under your chart name.
- Fix types, add required values, remove disallowed keys.
- Re-run
helm lintorhelm templateto confirm.
# wrong
replicaCount: "2"
# right
replicaCount: 2Update the chart schema if the values are intended
If a new value is legitimate, add it to values.schema.json so the chart accepts it.
{
"properties": {
"replicaCount": { "type": "integer" },
"image": { "type": "string" }
},
"required": ["image"]
}How to prevent it
- Run
helm lintin CI to validate values against the schema. - Keep
values.schema.jsonin sync with chart changes. - Do not quote integer values like replicaCount.