Files
cozystack/packages/extra/bootbox/values.schema.json
T
Mattia Eleuteri d3804ebea9 feat(api): refuse an application scheduling class its tenant does not allow
The lineage webhook keeps a pod on the tenant class when the
application names a class the tenant does not allow, but it can only
log that, on a pod the user never looks at. Refusing the application
at admission puts the error where the field was set, with the list of
classes that would be accepted.

An update that keeps the class is not refused, so an application whose
class was removed from the list after admission stays editable; the
webhook already keeps its pods on the tenant class. Tenants are left
out, because their spec.schedulingClass is the child tenant's class,
which the tenant chart's inheritance governs.

Users read the field description in the dashboard form and the API
schema, so it names the tenant setting that decides which classes are
accepted, says that only setting another value is refused, and that a
pod gets its class when it is created, so running pods keep theirs. The
field sits in its own README section, since a reader looking for
placement would not look under the unrelated heading it was appended
to.

Assisted-by: LLM
Signed-off-by: Mattia Eleuteri <mattia@hidora.io>
2026-11-23 08:05:09 +01:00

103 lines
2.9 KiB
JSON

{
"title": "Chart Values",
"type": "object",
"properties": {
"whitelistHTTP": {
"description": "Secure HTTP by enabling client networks whitelisting.",
"type": "boolean",
"default": true
},
"whitelist": {
"description": "List of client networks.",
"type": "array",
"default": [],
"items": {
"type": "string"
}
},
"machines": {
"description": "Configuration of physical machine instances.",
"type": "array",
"default": [],
"items": {
"type": "object",
"required": [
"arch",
"hostname",
"ip",
"leaseTime",
"uefi"
],
"properties": {
"arch": {
"description": "Architecture.",
"type": "string"
},
"hostname": {
"description": "Hostname.",
"type": "string"
},
"ip": {
"description": "IP address configuration.",
"type": "object",
"required": [
"address",
"gateway",
"netmask"
],
"properties": {
"address": {
"description": "IP address.",
"type": "string"
},
"gateway": {
"description": "IP gateway.",
"type": "string"
},
"netmask": {
"description": "Netmask.",
"type": "string"
}
}
},
"leaseTime": {
"description": "Lease time.",
"type": "integer"
},
"mac": {
"description": "MAC addresses.",
"type": "array",
"items": {
"type": "string"
}
},
"nameServers": {
"description": "Name servers.",
"type": "array",
"items": {
"type": "string"
}
},
"timeServers": {
"description": "Time servers.",
"type": "array",
"items": {
"type": "string"
}
},
"uefi": {
"description": "UEFI.",
"type": "boolean"
}
}
}
},
"schedulingClass": {
"description": "Name of a SchedulingClass CR (cluster-scoped, group cozystack.io) used in place of the tenant's for this application's pods. A pod gets its class when it is created, so running pods keep theirs until they are recreated. Must be the tenant's own class or one listed in the tenant's `allowedSchedulingClasses`. Setting any other value is refused, and the pods of an application whose class is not, or no longer, in that list get the tenant's class. Empty means inherit from the tenant.",
"type": "string",
"default": "",
"maxLength": 63
}
}
}