From 0fe7196c7ab25048b15d56753342bcda4d85aadd Mon Sep 17 00:00:00 2001 From: Christian Kellner Date: Tue, 12 Apr 2022 22:51:24 +0200 Subject: [PATCH] inputs/ostree: extract per-ref options schema Extract the schema for the per-reference options, which in this case confusingly is the single property "ref". --- inputs/org.osbuild.ostree | 21 +++++++++++++-------- 1 file changed, 13 insertions(+), 8 deletions(-) diff --git a/inputs/org.osbuild.ostree b/inputs/org.osbuild.ostree index df08790c..5af5fe05 100755 --- a/inputs/org.osbuild.ostree +++ b/inputs/org.osbuild.ostree @@ -21,6 +21,18 @@ from osbuild import inputs SCHEMA = """ +"definitions": { + "options": { + "type": "object", + "additionalProperties": false, + "properties": { + "ref": { + "type": "string", + "description": "OSTree reference to create for this commit" + } + } + } +}, "additionalProperties": false, "required": ["type", "origin", "references"], "properties": { @@ -46,14 +58,7 @@ SCHEMA = """ "minProperties": 1, "patternProperties": { ".*": { - "type": "object", - "additionalProperties": false, - "properties": { - "ref": { - "type": "string", - "description": "OSTree reference to create for this commit" - } - } + "$ref": "#/definitions/options" } } }]