Resources/Schemas/cdf-runtime.schema.json

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://cdf.epical.net/schemas/cdf-runtime.schema.json",
  "title": "CDF Runtime Manifest",
  "description": "Manifest for a CDF runtime configuration package. Placed at the config instance root directory (e.g. src/tsdc/01/cdf-runtime.json).",
  "type": "object",
  "required": ["platformId", "instanceId", "release"],
  "additionalProperties": false,
  "properties": {
    "platformId": {
      "type": "string",
      "pattern": "^[a-z][a-z0-9]*$",
      "description": "Platform identifier (e.g. 'tsdc', 'tscx')."
    },
    "instanceId": {
      "type": "string",
      "pattern": "^[0-9]+$",
      "description": "Instance identifier (e.g. '01', '02')."
    },
    "release": {
      "type": "string",
      "pattern": "^(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)(-[a-zA-Z0-9]+(\\.[a-zA-Z0-9]+)*)?(\\+[a-zA-Z0-9]+(\\.[a-zA-Z0-9]+)*)?$",
      "description": "Semantic version for the release lifecycle of this config package."
    },
    "description": {
      "type": "string",
      "description": "Human-readable description of the config instance."
    },
    "templates": {
      "type": "object",
      "additionalProperties": {
        "type": "string"
      },
      "description": "Template dependencies keyed by '<scope>/<name>/<version>'. Values are semver ranges (e.g. '^2.1.0')."
    }
  }
}