From 45b36566ca5ec8c8ebf373f7f54add5edcc47f8a Mon Sep 17 00:00:00 2001 From: Manuel Luzarreta Date: Fri, 8 Sep 2023 14:05:12 +0200 Subject: [PATCH] Skip create step when created == true - closes #4037 --- src/molecule/command/create.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/molecule/command/create.py b/src/molecule/command/create.py index a10bca06ee..a4a96f7c7d 100644 --- a/src/molecule/command/create.py +++ b/src/molecule/command/create.py @@ -41,6 +41,11 @@ def execute(self, action_args=None): """ self._config.state.change_state("driver", self._config.driver.name) + if self._config.state.created: + msg = "Skipping, instances already created." + LOG.warning(msg) + return + self._config.provisioner.create() self._config.state.change_state("created", True)