62 lines
2.7 KiB
JSON
62 lines
2.7 KiB
JSON
{
|
|
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
"$id": "https://devrunbook.local/schemas/instance-config.schema.json",
|
|
"title": "DevRunbook Non-Secret Instance Configuration",
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"required": ["apiVersion", "kind", "instance", "limits", "retention", "integrations", "telemetry"],
|
|
"properties": {
|
|
"apiVersion": {"const": "devrunbook.io/v1alpha1"},
|
|
"kind": {"const": "InstanceConfig"},
|
|
"instance": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"required": ["name", "publicBaseUrl", "registrationMode"],
|
|
"properties": {
|
|
"name": {"type": "string", "minLength": 1, "maxLength": 120},
|
|
"publicBaseUrl": {"type": "string", "format": "uri"},
|
|
"registrationMode": {"enum": ["closed", "admin-invite"]}
|
|
}
|
|
},
|
|
"limits": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"required": ["maxImportBytes", "maxExpandedArchiveBytes", "maxArchiveFiles", "maxSingleFileBytes", "maxPromptBytes", "maxEvidenceBytes"],
|
|
"properties": {
|
|
"maxImportBytes": {"type": "integer", "minimum": 1048576, "maximum": 1073741824},
|
|
"maxExpandedArchiveBytes": {"type": "integer", "minimum": 1048576, "maximum": 2147483648},
|
|
"maxArchiveFiles": {"type": "integer", "minimum": 10, "maximum": 10000},
|
|
"maxSingleFileBytes": {"type": "integer", "minimum": 1024, "maximum": 536870912},
|
|
"maxPromptBytes": {"type": "integer", "minimum": 65536, "maximum": 104857600},
|
|
"maxEvidenceBytes": {"type": "integer", "minimum": 1024, "maximum": 10485760}
|
|
}
|
|
},
|
|
"retention": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"required": ["artifactDays", "snapshotCountPerRepository", "auditEventDays", "operationalLogDays"],
|
|
"properties": {
|
|
"artifactDays": {"type": "integer", "minimum": 1, "maximum": 3650},
|
|
"snapshotCountPerRepository": {"type": "integer", "minimum": 1, "maximum": 1000},
|
|
"auditEventDays": {"type": "integer", "minimum": 30, "maximum": 3650},
|
|
"operationalLogDays": {"type": "integer", "minimum": 1, "maximum": 365}
|
|
}
|
|
},
|
|
"integrations": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"required": ["giteaPrivateNetworkPolicy", "allowedGiteaHosts"],
|
|
"properties": {
|
|
"giteaPrivateNetworkPolicy": {"enum": ["deny", "allow-explicit-hosts"]},
|
|
"allowedGiteaHosts": {"type": "array", "uniqueItems": true, "items": {"type": "string", "minLength": 1, "maxLength": 253}}
|
|
}
|
|
},
|
|
"telemetry": {
|
|
"type": "object",
|
|
"additionalProperties": false,
|
|
"required": ["enabled"],
|
|
"properties": {"enabled": {"const": false}}
|
|
}
|
|
}
|
|
}
|