fix: disable parallel operations for Pulumi as backend does not support that, yet
This commit is contained in:
parent
7d6135e099
commit
e74bca7199
@ -342,10 +342,28 @@ def _render(stacks):
|
||||
logger.info("{} uses Pulumi, render skipped.".format(s.stackname))
|
||||
|
||||
|
||||
def _anyPulumi(step):
|
||||
for stack in step:
|
||||
if stack.mode == "pulumi":
|
||||
return True
|
||||
|
||||
return False
|
||||
|
||||
|
||||
def _provision(cb, stacks):
|
||||
"""Utility function to reuse code between tasks"""
|
||||
for step in sort_stacks(cb, stacks):
|
||||
if step:
|
||||
# if there are any Pulumi stacks in the step execute serial
|
||||
if _anyPulumi(step):
|
||||
for stack in step:
|
||||
status = stack.get_status()
|
||||
if not status:
|
||||
stack.create()
|
||||
else:
|
||||
stack.update()
|
||||
|
||||
else:
|
||||
with ThreadPoolExecutor(max_workers=len(step)) as group:
|
||||
futures = []
|
||||
for stack in step:
|
||||
|
Loading…
Reference in New Issue
Block a user