diff --git a/config.json.example b/config.json.example index bdeb904..c1942fd 100644 --- a/config.json.example +++ b/config.json.example @@ -9,4 +9,4 @@ } } ] -} \ No newline at end of file +} diff --git a/src/types/config.schema.json b/src/types/config.schema.json index 75fdfb6..166eb57 100644 --- a/src/types/config.schema.json +++ b/src/types/config.schema.json @@ -31,33 +31,18 @@ "type": "object", "properties": { "defaultAction": { - "type": "string", - "enum": [ - "ACCEPT", - "DROP", - "SKIP" - ] + "$ref": "#/$defs/filterAction" }, "owners": { "type": "object", "additionalProperties": { - "type": "string", - "enum": [ - "ACCEPT", - "DROP", - "SKIP" - ] + "$ref": "#/$defs/filterAction" } }, "handlers": { "type": "object", "additionalProperties": { - "type": "string", - "enum": [ - "ACCEPT", - "DROP", - "SKIP" - ] + "$ref": "#/$defs/filterAction" } } }, @@ -80,5 +65,15 @@ "required": [ "networks" ], - "additionalProperties": false -} \ No newline at end of file + "additionalProperties": false, + "$defs": { + "filterAction": { + "type": "string", + "enum": [ + "ACCEPT", + "DROP", + "SKIP" + ] + } + } +}