|
| 1 | +{ |
| 2 | + "id": "https://raw.githubusercontent.com/databricks/cli/feat/labs/cmd/labs/project/schema.json#", |
| 3 | + "$schema": "http://json-schema.org/draft-04/schema", |
| 4 | + "definitions": { |
| 5 | + "entrypoint": { |
| 6 | + "type": "object", |
| 7 | + "properties": { |
| 8 | + "require_running_cluster": { |
| 9 | + "type": "boolean", |
| 10 | + "default": false |
| 11 | + }, |
| 12 | + "is_unauthenticated": { |
| 13 | + "type": "boolean", |
| 14 | + "default": false |
| 15 | + }, |
| 16 | + "is_account_level": { |
| 17 | + "type": "boolean", |
| 18 | + "default": false |
| 19 | + }, |
| 20 | + "is_bundle_aware": { |
| 21 | + "type": "boolean", |
| 22 | + "default": false |
| 23 | + } |
| 24 | + } |
| 25 | + }, |
| 26 | + "hook": { |
| 27 | + "type": "object", |
| 28 | + "$ref": "#/definitions/entrypoint", |
| 29 | + "unevaluatedProperties": true, |
| 30 | + "properties": { |
| 31 | + "script": { |
| 32 | + "type": "string", |
| 33 | + "pattern": "^[A-Za-z0-9_-/\\.]+$" |
| 34 | + }, |
| 35 | + "min_runtime_version": { |
| 36 | + "type": "string", |
| 37 | + "pattern": "^[0-9]+.[0-9]+$" |
| 38 | + }, |
| 39 | + "require_databricks_connect": { |
| 40 | + "type": "boolean", |
| 41 | + "default": false |
| 42 | + }, |
| 43 | + "warehouse_types": { |
| 44 | + "enum": [ "PRO", "CLASSIC", "TYPE_UNSPECIFIED" ] |
| 45 | + } |
| 46 | + } |
| 47 | + }, |
| 48 | + "alphanum": { |
| 49 | + "type": "string", |
| 50 | + "pattern": "^[a-z0-9-]$" |
| 51 | + }, |
| 52 | + "command": { |
| 53 | + "type": "object", |
| 54 | + "$ref": "#/definitions/entrypoint", |
| 55 | + "unevaluatedProperties": true, |
| 56 | + "required": ["name", "description"], |
| 57 | + "properties": { |
| 58 | + "name": { |
| 59 | + "$ref": "#/definitions/alphanum" |
| 60 | + }, |
| 61 | + "description": { |
| 62 | + "type": "string" |
| 63 | + }, |
| 64 | + "table_template": { |
| 65 | + "type": "string" |
| 66 | + }, |
| 67 | + "flags": { |
| 68 | + "$ref": "#/definitions/flag" |
| 69 | + } |
| 70 | + } |
| 71 | + }, |
| 72 | + "flag": { |
| 73 | + "type": "object", |
| 74 | + "required": ["name", "description"], |
| 75 | + "properties": { |
| 76 | + "name": { |
| 77 | + "$ref": "#/definitions/alphanum" |
| 78 | + }, |
| 79 | + "description": { |
| 80 | + "type": "string" |
| 81 | + }, |
| 82 | + "default": {} |
| 83 | + } |
| 84 | + } |
| 85 | + }, |
| 86 | + "type": "object", |
| 87 | + "additionalProperties": false, |
| 88 | + "required": ["name", "description", "entrypoint"], |
| 89 | + "properties": { |
| 90 | + "$version": { |
| 91 | + "type": "integer", |
| 92 | + "default": 1 |
| 93 | + }, |
| 94 | + "name": { |
| 95 | + "$ref": "#/definitions/alphanum", |
| 96 | + "description": "Name of the project" |
| 97 | + }, |
| 98 | + "description": { |
| 99 | + "type": "string", |
| 100 | + "description": "Short description of the project" |
| 101 | + }, |
| 102 | + "entrypoint": { |
| 103 | + "type": "string", |
| 104 | + "description": "Script that routes subcommands" |
| 105 | + }, |
| 106 | + "min_python": { |
| 107 | + "type": "string", |
| 108 | + "pattern": "^3.[0-9]+$", |
| 109 | + "description": "Minimal Python version required" |
| 110 | + }, |
| 111 | + "install": { |
| 112 | + "$ref": "#/definitions/hook", |
| 113 | + "description": "Installation configuration" |
| 114 | + }, |
| 115 | + "uninstall": { |
| 116 | + "$ref": "#/definitions/hook" |
| 117 | + }, |
| 118 | + "commands": { |
| 119 | + "type": "array", |
| 120 | + "description": "Exposed commands", |
| 121 | + "items": { |
| 122 | + "$ref": "#/definitions/command" |
| 123 | + } |
| 124 | + } |
| 125 | + } |
| 126 | +} |
0 commit comments