Skip to content

Commit

Permalink
Add withDatahubStart switch to the start_environment method to su…
Browse files Browse the repository at this point in the history
…pport starting an environment without starting the datahubs within it.

Signed-off-by: Jesus Perez Rey <jprey@bluemetrix.com>
  • Loading branch information
chusopr committed Oct 19, 2022
1 parent eeb420a commit 0cc5e96
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/cdpy/environments.py
Original file line number Diff line number Diff line change
Expand Up @@ -156,14 +156,15 @@ def delete_environment(self, name, cascade=False, force=False):
forced=force
)

def start_environment(self, name):
def start_environment(self, name, datahub_start=True):
return self.sdk.call(
svc='environments', func='start_environment', ret_field='environment', squelch=[
Squelch(field='error_code', value='CONFLICT', default=self.describe_environment(name),
warning='Environment %s is already scheduled to start' % name)
],
environmentName=name
)
environmentName=name,
withDatahubStart=datahub_start
)

def set_password(self, password, environment_names=None):
payload = dict(password=password)
Expand Down

0 comments on commit 0cc5e96

Please sign in to comment.