From 7611492f9c1193543e39ec1259e63007bbead6d7 Mon Sep 17 00:00:00 2001 From: Joffrey F Date: Thu, 17 Aug 2017 15:52:08 -0700 Subject: [PATCH] Update schemas to prevent invalid properties in deploy.resources Signed-off-by: Joffrey F --- compose/config/config_schema_v3.0.json | 3 ++- compose/config/config_schema_v3.1.json | 3 ++- compose/config/config_schema_v3.2.json | 3 ++- compose/config/config_schema_v3.3.json | 3 ++- compose/config/config_schema_v3.4.json | 7 +++++-- 5 files changed, 13 insertions(+), 6 deletions(-) diff --git a/compose/config/config_schema_v3.0.json b/compose/config/config_schema_v3.0.json index fbcd8bb85..f39344cfb 100644 --- a/compose/config/config_schema_v3.0.json +++ b/compose/config/config_schema_v3.0.json @@ -240,7 +240,8 @@ "properties": { "limits": {"$ref": "#/definitions/resource"}, "reservations": {"$ref": "#/definitions/resource"} - } + }, + "additionalProperties": false }, "restart_policy": { "type": "object", diff --git a/compose/config/config_schema_v3.1.json b/compose/config/config_schema_v3.1.json index b7037485f..719c0fa7a 100644 --- a/compose/config/config_schema_v3.1.json +++ b/compose/config/config_schema_v3.1.json @@ -269,7 +269,8 @@ "properties": { "limits": {"$ref": "#/definitions/resource"}, "reservations": {"$ref": "#/definitions/resource"} - } + }, + "additionalProperties": false }, "restart_policy": { "type": "object", diff --git a/compose/config/config_schema_v3.2.json b/compose/config/config_schema_v3.2.json index 70ff6ce05..b26b2c6c6 100644 --- a/compose/config/config_schema_v3.2.json +++ b/compose/config/config_schema_v3.2.json @@ -313,7 +313,8 @@ "properties": { "limits": {"$ref": "#/definitions/resource"}, "reservations": {"$ref": "#/definitions/resource"} - } + }, + "additionalProperties": false }, "restart_policy": { "type": "object", diff --git a/compose/config/config_schema_v3.3.json b/compose/config/config_schema_v3.3.json index e69116c38..f1eb9a661 100644 --- a/compose/config/config_schema_v3.3.json +++ b/compose/config/config_schema_v3.3.json @@ -348,7 +348,8 @@ "properties": { "limits": {"$ref": "#/definitions/resource"}, "reservations": {"$ref": "#/definitions/resource"} - } + }, + "additionalProperties": false }, "restart_policy": { "type": "object", diff --git a/compose/config/config_schema_v3.4.json b/compose/config/config_schema_v3.4.json index ce9512076..5a110a888 100644 --- a/compose/config/config_schema_v3.4.json +++ b/compose/config/config_schema_v3.4.json @@ -84,7 +84,9 @@ "dockerfile": {"type": "string"}, "args": {"$ref": "#/definitions/list_or_dict"}, "labels": {"$ref": "#/definitions/list_or_dict"}, - "cache_from": {"$ref": "#/definitions/list_of_strings"} + "cache_from": {"$ref": "#/definitions/list_of_strings"}, + "network": {"type": "string"}, + "target": {"type": "string"} }, "additionalProperties": false } @@ -351,7 +353,8 @@ "properties": { "limits": {"$ref": "#/definitions/resource"}, "reservations": {"$ref": "#/definitions/resource"} - } + }, + "additionalProperties": false }, "restart_policy": { "type": "object",