From 4c84c3d6ee61ccbde9e7eb16ef855cc4527a1c1a Mon Sep 17 00:00:00 2001 From: Lucas De Souza Date: Wed, 23 Nov 2022 09:32:15 -0600 Subject: [PATCH] update config.d with new fields Signed-off-by: Lucas De Souza --- plugins/catalog-backend/config.d.ts | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/plugins/catalog-backend/config.d.ts b/plugins/catalog-backend/config.d.ts index daa70656bc..16094af489 100644 --- a/plugins/catalog-backend/config.d.ts +++ b/plugins/catalog-backend/config.d.ts @@ -38,6 +38,32 @@ export interface Config { * E.g. ["Component", "API", "Template", "Location"] */ allow: Array; + /** + * Limit this rule to a specific location + * + * Example with a fixed location + * { "type": "url", "target": "https://github.com/a/b/blob/file.yaml} + * + * Example using a Regex + * { "type": "url", "match": "https://github.com/a/*} + * + */ + location?: Array<{ + /** + * The type of location, e.g. "url". + */ + type: string; + /** + * The target URL of the location, e.g. + * "https://github.com/org/repo/blob/master/users.yaml". + */ + target?: string; + /** + * The target Regex of the location, e.g. + * "https://github.com/org/*. + */ + match?: string; + }>; }>; /**