diff --git a/roles/fedmsg/base/templates/endpoints-bodhi.py.j2 b/roles/fedmsg/base/templates/endpoints-bodhi.py.j2 index 98bd02e1e3..962917a41f 100644 --- a/roles/fedmsg/base/templates/endpoints-bodhi.py.j2 +++ b/roles/fedmsg/base/templates/endpoints-bodhi.py.j2 @@ -1,7 +1,24 @@ +{% if datacenter == 'phx2' %} {% if env == 'staging' %} suffix = 'stg.phx2.fedoraproject.org' {% else %} suffix = 'phx2.fedoraproject.org' +vpn_suffix = 'vpn.fedoraproject.org' +{% endif %} +{% elif datacenter == 'iad2' %} +{% if env == 'staging' %} +suffix = 'stg.iad2.fedoraproject.org' +{% else %} +suffix = 'iad2.fedoraproject.org' +vpn_suffix = 'vpn.fedoraproject.org' +{% endif %} +{% else %} +{% if env == 'staging' %} +suffix = 'stg.fedoraproject.org' +{% else %} +suffix = 'fedoraproject.org' +vpn_suffix = 'vpn.fedoraproject.org' +{% endif %} {% endif %} diff --git a/roles/fedmsg/base/templates/endpoints-bugzilla2fedmsg.py.j2 b/roles/fedmsg/base/templates/endpoints-bugzilla2fedmsg.py.j2 index e91a55f5f2..a865b43934 100644 --- a/roles/fedmsg/base/templates/endpoints-bugzilla2fedmsg.py.j2 +++ b/roles/fedmsg/base/templates/endpoints-bugzilla2fedmsg.py.j2 @@ -1,7 +1,24 @@ +{% if datacenter == 'phx2' %} {% if env == 'staging' %} suffix = 'stg.phx2.fedoraproject.org' {% else %} suffix = 'phx2.fedoraproject.org' +vpn_suffix = 'vpn.fedoraproject.org' +{% endif %} +{% elif datacenter == 'iad2' %} +{% if env == 'staging' %} +suffix = 'stg.iad2.fedoraproject.org' +{% else %} +suffix = 'iad2.fedoraproject.org' +vpn_suffix = 'vpn.fedoraproject.org' +{% endif %} +{% else %} +{% if env == 'staging' %} +suffix = 'stg.fedoraproject.org' +{% else %} +suffix = 'fedoraproject.org' +vpn_suffix = 'vpn.fedoraproject.org' +{% endif %} {% endif %} config = dict( diff --git a/roles/fedmsg/base/templates/endpoints-fedbadges.py.j2 b/roles/fedmsg/base/templates/endpoints-fedbadges.py.j2 index 7d24e9d450..d1c93e8c69 100644 --- a/roles/fedmsg/base/templates/endpoints-fedbadges.py.j2 +++ b/roles/fedmsg/base/templates/endpoints-fedbadges.py.j2 @@ -1,7 +1,24 @@ +{% if datacenter == 'phx2' %} {% if env == 'staging' %} suffix = 'stg.phx2.fedoraproject.org' {% else %} suffix = 'phx2.fedoraproject.org' +vpn_suffix = 'vpn.fedoraproject.org' +{% endif %} +{% elif datacenter == 'iad2' %} +{% if env == 'staging' %} +suffix = 'stg.iad2.fedoraproject.org' +{% else %} +suffix = 'iad2.fedoraproject.org' +vpn_suffix = 'vpn.fedoraproject.org' +{% endif %} +{% else %} +{% if env == 'staging' %} +suffix = 'stg.fedoraproject.org' +{% else %} +suffix = 'fedoraproject.org' +vpn_suffix = 'vpn.fedoraproject.org' +{% endif %} {% endif %} config = dict( diff --git a/roles/fedmsg/base/templates/endpoints-fedocal.py.j2 b/roles/fedmsg/base/templates/endpoints-fedocal.py.j2 index f213dcc25d..02c302414a 100644 --- a/roles/fedmsg/base/templates/endpoints-fedocal.py.j2 +++ b/roles/fedmsg/base/templates/endpoints-fedocal.py.j2 @@ -1,7 +1,24 @@ +{% if datacenter == 'phx2' %} {% if env == 'staging' %} suffix = 'stg.phx2.fedoraproject.org' {% else %} suffix = 'phx2.fedoraproject.org' +vpn_suffix = 'vpn.fedoraproject.org' +{% endif %} +{% elif datacenter == 'iad2' %} +{% if env == 'staging' %} +suffix = 'stg.iad2.fedoraproject.org' +{% else %} +suffix = 'iad2.fedoraproject.org' +vpn_suffix = 'vpn.fedoraproject.org' +{% endif %} +{% else %} +{% if env == 'staging' %} +suffix = 'stg.fedoraproject.org' +{% else %} +suffix = 'fedoraproject.org' +vpn_suffix = 'vpn.fedoraproject.org' +{% endif %} {% endif %} config = dict( diff --git a/roles/fedmsg/base/templates/endpoints-fmn-web.py.j2 b/roles/fedmsg/base/templates/endpoints-fmn-web.py.j2 index 550272b25f..0c3327343f 100644 --- a/roles/fedmsg/base/templates/endpoints-fmn-web.py.j2 +++ b/roles/fedmsg/base/templates/endpoints-fmn-web.py.j2 @@ -1,7 +1,24 @@ +{% if datacenter == 'phx2' %} {% if env == 'staging' %} suffix = 'stg.phx2.fedoraproject.org' {% else %} suffix = 'phx2.fedoraproject.org' +vpn_suffix = 'vpn.fedoraproject.org' +{% endif %} +{% elif datacenter == 'iad2' %} +{% if env == 'staging' %} +suffix = 'stg.iad2.fedoraproject.org' +{% else %} +suffix = 'iad2.fedoraproject.org' +vpn_suffix = 'vpn.fedoraproject.org' +{% endif %} +{% else %} +{% if env == 'staging' %} +suffix = 'stg.fedoraproject.org' +{% else %} +suffix = 'fedoraproject.org' +vpn_suffix = 'vpn.fedoraproject.org' +{% endif %} {% endif %} config = dict( diff --git a/roles/fedmsg/base/templates/endpoints-hotness.py.j2 b/roles/fedmsg/base/templates/endpoints-hotness.py.j2 index 35b494b7a3..13d1e90f55 100644 --- a/roles/fedmsg/base/templates/endpoints-hotness.py.j2 +++ b/roles/fedmsg/base/templates/endpoints-hotness.py.j2 @@ -1,7 +1,24 @@ +{% if datacenter == 'phx2' %} {% if env == 'staging' %} suffix = 'stg.phx2.fedoraproject.org' {% else %} suffix = 'phx2.fedoraproject.org' +vpn_suffix = 'vpn.fedoraproject.org' +{% endif %} +{% elif datacenter == 'iad2' %} +{% if env == 'staging' %} +suffix = 'stg.iad2.fedoraproject.org' +{% else %} +suffix = 'iad2.fedoraproject.org' +vpn_suffix = 'vpn.fedoraproject.org' +{% endif %} +{% else %} +{% if env == 'staging' %} +suffix = 'stg.fedoraproject.org' +{% else %} +suffix = 'fedoraproject.org' +vpn_suffix = 'vpn.fedoraproject.org' +{% endif %} {% endif %} config = dict( diff --git a/roles/fedmsg/base/templates/endpoints-mailman.py.j2 b/roles/fedmsg/base/templates/endpoints-mailman.py.j2 index 88e09f3e33..0846fc565c 100644 --- a/roles/fedmsg/base/templates/endpoints-mailman.py.j2 +++ b/roles/fedmsg/base/templates/endpoints-mailman.py.j2 @@ -1,7 +1,24 @@ +{% if datacenter == 'phx2' %} {% if env == 'staging' %} suffix = 'stg.phx2.fedoraproject.org' {% else %} suffix = 'phx2.fedoraproject.org' +vpn_suffix = 'vpn.fedoraproject.org' +{% endif %} +{% elif datacenter == 'iad2' %} +{% if env == 'staging' %} +suffix = 'stg.iad2.fedoraproject.org' +{% else %} +suffix = 'iad2.fedoraproject.org' +vpn_suffix = 'vpn.fedoraproject.org' +{% endif %} +{% else %} +{% if env == 'staging' %} +suffix = 'stg.fedoraproject.org' +{% else %} +suffix = 'fedoraproject.org' +vpn_suffix = 'vpn.fedoraproject.org' +{% endif %} {% endif %} config = dict( diff --git a/roles/fedmsg/base/templates/endpoints-mbs-backend.py.j2 b/roles/fedmsg/base/templates/endpoints-mbs-backend.py.j2 index 39a144f038..5de05a4f97 100644 --- a/roles/fedmsg/base/templates/endpoints-mbs-backend.py.j2 +++ b/roles/fedmsg/base/templates/endpoints-mbs-backend.py.j2 @@ -1,8 +1,26 @@ +{% if datacenter == 'phx2' %} {% if env == 'staging' %} suffix = 'stg.phx2.fedoraproject.org' {% else %} suffix = 'phx2.fedoraproject.org' +vpn_suffix = 'vpn.fedoraproject.org' {% endif %} +{% elif datacenter == 'iad2' %} +{% if env == 'staging' %} +suffix = 'stg.iad2.fedoraproject.org' +{% else %} +suffix = 'iad2.fedoraproject.org' +vpn_suffix = 'vpn.fedoraproject.org' +{% endif %} +{% else %} +{% if env == 'staging' %} +suffix = 'stg.fedoraproject.org' +{% else %} +suffix = 'fedoraproject.org' +vpn_suffix = 'vpn.fedoraproject.org' +{% endif %} +{% endif %} + config = dict( endpoints={ diff --git a/roles/fedmsg/base/templates/endpoints-odcs-backend.py.j2 b/roles/fedmsg/base/templates/endpoints-odcs-backend.py.j2 index bf60b815e3..b8aa339033 100644 --- a/roles/fedmsg/base/templates/endpoints-odcs-backend.py.j2 +++ b/roles/fedmsg/base/templates/endpoints-odcs-backend.py.j2 @@ -1,7 +1,24 @@ +{% if datacenter == 'phx2' %} {% if env == 'staging' %} suffix = 'stg.phx2.fedoraproject.org' {% else %} suffix = 'phx2.fedoraproject.org' +vpn_suffix = 'vpn.fedoraproject.org' +{% endif %} +{% elif datacenter == 'iad2' %} +{% if env == 'staging' %} +suffix = 'stg.iad2.fedoraproject.org' +{% else %} +suffix = 'iad2.fedoraproject.org' +vpn_suffix = 'vpn.fedoraproject.org' +{% endif %} +{% else %} +{% if env == 'staging' %} +suffix = 'stg.fedoraproject.org' +{% else %} +suffix = 'fedoraproject.org' +vpn_suffix = 'vpn.fedoraproject.org' +{% endif %} {% endif %} config = dict( diff --git a/roles/fedmsg/base/templates/endpoints.py.j2 b/roles/fedmsg/base/templates/endpoints.py.j2 index b8c4660f50..b3e714b637 100644 --- a/roles/fedmsg/base/templates/endpoints.py.j2 +++ b/roles/fedmsg/base/templates/endpoints.py.j2 @@ -1,11 +1,25 @@ +{% if datacenter == 'phx2' %} {% if env == 'staging' %} suffix = 'stg.phx2.fedoraproject.org' -non_phx_suffix = 'stg.fedoraproject.org' {% else %} suffix = 'phx2.fedoraproject.org' -non_phx_suffix = 'fedoraproject.org' vpn_suffix = 'vpn.fedoraproject.org' {% endif %} +{% elif datacenter == 'iad2' %} +{% if env == 'staging' %} +suffix = 'stg.iad2.fedoraproject.org' +{% else %} +suffix = 'iad2.fedoraproject.org' +vpn_suffix = 'vpn.fedoraproject.org' +{% endif %} +{% else %} +{% if env == 'staging' %} +suffix = 'stg.fedoraproject.org' +{% else %} +suffix = 'fedoraproject.org' +vpn_suffix = 'vpn.fedoraproject.org' +{% endif %} +{% endif %} config = dict( diff --git a/roles/fedmsg/base/templates/logging.py.j2 b/roles/fedmsg/base/templates/logging.py.j2 index b4dd00f70f..637cc2bde2 100644 --- a/roles/fedmsg/base/templates/logging.py.j2 +++ b/roles/fedmsg/base/templates/logging.py.j2 @@ -218,7 +218,13 @@ config = dict( "formatter": "hefty", "filters": ["context"], "level": "ERROR", +{% if datacenter == 'phx2' %} "mailhost": "bastion.phx2.fedoraproject.org", +{% elif datacenter == 'iad2' %} + "mailhost": "bastion.iad2.fedoraproject.org", +{% else %} + "mailhost": "bastion.vpn.fedoraproject.org", +{% endif %} "fromaddr": "fedmsg@fedoraproject.org", "toaddrs": [ {% for recipient in fedmsg_error_recipients %} diff --git a/roles/fedmsg/base/templates/relay.py.j2 b/roles/fedmsg/base/templates/relay.py.j2 index 04cda50bb9..f98b80a4b9 100644 --- a/roles/fedmsg/base/templates/relay.py.j2 +++ b/roles/fedmsg/base/templates/relay.py.j2 @@ -1,9 +1,24 @@ +{% if datacenter == 'phx2' %} {% if env == 'staging' %} suffix = 'stg.phx2.fedoraproject.org' -non_phx_suffix = 'stg.fedoraproject.org' {% else %} suffix = 'phx2.fedoraproject.org' -non_phx_suffix = 'fedoraproject.org' +vpn_suffix = 'vpn.fedoraproject.org' +{% endif %} +{% elif datacenter == 'iad2' %} +{% if env == 'staging' %} +suffix = 'stg.iad2.fedoraproject.org' +{% else %} +suffix = 'iad2.fedoraproject.org' +vpn_suffix = 'vpn.fedoraproject.org' +{% endif %} +{% else %} +{% if env == 'staging' %} +suffix = 'stg.fedoraproject.org' +{% else %} +suffix = 'fedoraproject.org' +vpn_suffix = 'vpn.fedoraproject.org' +{% endif %} {% endif %} # This is just an extension of fedmsg.d/endpoints.py. This dict @@ -24,26 +39,6 @@ config = dict( # It is also used by the mediawiki php plugin which, due to the oddities of # php, can't maintain a single passive-bind endpoint of it's own. relay_inbound=[ - {% if 'persistent_cloud' in group_names %} - - # Stuff from the cloud has to go through our external proxy first.. - #"tcp://hub.fedoraproject.org:9941", - - # ...and normally, we'd like them to go through round-robin, but we're - # not getting messages in from proxies across the vpn. So, only use - # proxy01 for now. - "tcp://209.132.181.16:9941", - {% elif 'fedmsg_qa_network' in group_names %} - - # We want the retrace (and other) boxes to talk to the *internal* IP of - # proxy01, because otherwise the RHIT firewall blocks them. - "tcp://proxy01.phx2.fedoraproject.org:9941", - - {% elif 'fedmsg_qa_network_stg' in group_names %} - - "tcp://proxy01.stg.phx2.fedoraproject.org:9941", - - {% else %} # Primarily, scripts from inside phx2 connect here. # Furthermore, scripts from outside (coprs, secondary arch koji) connect