Skip to content

Commit 86d567b

Browse files
author
Sam J Sharpe
committed
Add configuration to connect to carrenza preview
1 parent 3831dba commit 86d567b

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

fabfile.py

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -181,7 +181,10 @@ def _set_gateway(name):
181181
setting and makes sure that the correct known_hosts file will be consulted,
182182
then dynamically fetches a list of hosts from the gateway box.
183183
"""
184-
env.gateway = 'jumpbox.{0}.alphagov.co.uk'.format(name)
184+
if name == 'preview_carrenza':
185+
env.gateway = 'jumpbox.provider1.preview.govuk.service.gov.uk'
186+
else:
187+
env.gateway = 'jumpbox.{0}.alphagov.co.uk'.format(name)
185188
env.system_known_hosts = _fetch_known_hosts()
186189
env.roledefs.fetch()
187190

@@ -210,6 +213,11 @@ def preview():
210213
"""Select preview environment"""
211214
_set_gateway('preview')
212215

216+
@task
217+
def preview_carrenza():
218+
"""Select preview environment"""
219+
_set_gateway('preview_carrenza')
220+
213221
@task
214222
def all():
215223
"""Select all machines in current environment"""

0 commit comments

Comments
 (0)