From ae5e505de0c7a6d75031da4642c6f14f18101dac Mon Sep 17 00:00:00 2001 From: aiordache Date: Mon, 17 Aug 2020 11:59:23 +0200 Subject: [PATCH] set scale default to 1 on deploy Signed-off-by: aiordache --- compose/project.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/compose/project.py b/compose/project.py index 0ae5721bc..a5bb39b93 100644 --- a/compose/project.py +++ b/compose/project.py @@ -318,6 +318,8 @@ class Project: ) if replicas: scale = replicas + if scale is None: + return 1 # deploy may contain placement constraints introduced in v3.8 max_replicas = deploy_dict.get('placement', {}).get( 'max_replicas_per_node',