From 5b6191e6536abc4bbbae902c384bfa531315a897 Mon Sep 17 00:00:00 2001 From: Joey Payne Date: Mon, 20 Feb 2017 13:18:52 -0700 Subject: [PATCH] Add cache_from to build opts Signed-off-by: Joey Payne --- compose/config/config_schema_v3.1.json | 3 ++- compose/service.py | 1 + 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/compose/config/config_schema_v3.1.json b/compose/config/config_schema_v3.1.json index b7037485f..77c2d35cb 100644 --- a/compose/config/config_schema_v3.1.json +++ b/compose/config/config_schema_v3.1.json @@ -71,7 +71,8 @@ "properties": { "context": {"type": "string"}, "dockerfile": {"type": "string"}, - "args": {"$ref": "#/definitions/list_or_dict"} + "args": {"$ref": "#/definitions/list_or_dict"}, + "cache_from": {"type": "#/definitions/list_of_strings"} }, "additionalProperties": false } diff --git a/compose/service.py b/compose/service.py index 9f2fc68b4..023efa274 100644 --- a/compose/service.py +++ b/compose/service.py @@ -802,6 +802,7 @@ class Service(object): nocache=no_cache, dockerfile=build_opts.get('dockerfile', None), buildargs=build_opts.get('args', None), + cache_from=build_opts.get('cache_from', None), ) try: