cuddle/schemas/base.json

139 lines
3.8 KiB
JSON
Raw Normal View History

2022-08-09 13:23:30 +02:00
{
"$schema": "http://json-schema.org/draft-07/schema#",
"additionalProperties": true,
2022-08-09 13:23:30 +02:00
"properties": {
"base": {
"title": "Base url from which to base current cuddle plan on",
"description": "Base url from which to construct current cuddle plan, is recursive",
"oneOf": [
{
"type": "string",
"title": "The url of the parameter"
},
{
"type": "boolean",
2022-08-09 13:26:41 +02:00
"title": "Whether it is enabled or not"
2022-08-09 13:23:30 +02:00
}
]
2022-08-09 17:53:53 +02:00
},
2022-08-10 23:31:07 +02:00
"vars": {
"type": "object",
"title": "your collection of variables to be available to cuddle",
"patternProperties": {
"^.*$": {
"anyOf": [
{
"type": "string"
},
{
"type": "object"
},
{
"type": "array"
2022-08-10 23:31:07 +02:00
}
]
}
},
"additionalProperties": false
},
2022-08-09 17:53:53 +02:00
"scripts": {
"type": "object",
"title": "Scripts the cuddle cli can execute",
"description": "Scripts the cuddle cli can execute 'cuddle x my-awesome-script'",
2022-08-10 23:31:07 +02:00
"additionalProperties": false,
2022-08-09 17:53:53 +02:00
"patternProperties": {
"^.*$": {
"required": [
"type"
],
2022-08-10 23:34:52 +02:00
"additionalProperties": false,
2022-08-09 17:53:53 +02:00
"properties": {
"type": {
"enum": [
"shell",
"dagger"
]
2022-08-10 12:34:04 +02:00
},
"description": {
"type": "string"
2022-08-10 23:31:07 +02:00
},
"vars": {
"type": "object",
"title": "your collection of variables to be available to cuddle",
"patternProperties": {
"^.*$": {
2022-08-11 02:03:19 +02:00
"type": "string"
}
},
"additionalProperties": false
2022-08-12 00:54:22 +02:00
},
"args": {
"title": "arguments to send to the specified script",
"type": "object",
"patternProperties": {
"^.*$": {
"anyOf": [
{
"type": "object",
"required": [
"type",
"name"
],
"properties": {
"type": {
"enum": [
"flag"
]
},
"name": {
"type": "string"
},
"description": {
"type": "string"
},
"required": {
"type": "boolean"
},
"default": {
"type": "string"
}
}
},
2022-08-12 00:54:22 +02:00
{
"type": "object",
"required": [
"type",
"key"
],
"additionalProperties": false,
"properties": {
"type": {
"enum": [
"env"
]
},
"description": {
"type": "string"
},
2022-08-12 00:54:22 +02:00
"key": {
"title": "the environment key to pull arg from",
"type": "string"
}
}
}
]
}
}
2022-08-10 23:34:21 +02:00
}
2022-08-09 17:53:53 +02:00
}
}
}
2022-08-09 13:23:30 +02:00
}
},
"required": [
"base"
],
"type": "object",
"title": "Cuddle base schema"
}