Title: [288230] trunk/Tools/CISupport/ews-build
Revision
288230
Author
aakash_j...@apple.com
Date
2022-01-19 12:23:22 -0800 (Wed, 19 Jan 2022)

Log Message

[ews] Improve support for required changes for ews uat instance
https://bugs.webkit.org/show_bug.cgi?id=235355

Reviewed by Jonathan Bedard.

* Tools/CISupport/ews-build/events.py:
* Tools/CISupport/ews-build/master.cfg:
* Tools/CISupport/ews-build/send_email.py:
* Tools/CISupport/ews-build/steps.py:

Canonical link: https://commits.webkit.org/246187@main

Modified Paths

Diff

Modified: trunk/Tools/CISupport/ews-build/events.py (288229 => 288230)


--- trunk/Tools/CISupport/ews-build/events.py	2022-01-19 20:21:54 UTC (rev 288229)
+++ trunk/Tools/CISupport/ews-build/events.py	2022-01-19 20:23:22 UTC (rev 288230)
@@ -37,6 +37,7 @@
 from twisted.web.iweb import IBodyProducer
 from zope.interface import implementer
 
+custom_suffix = '-uat' if os.getenv('BUILDBOT_UAT') else ''
 
 @implementer(IBodyProducer)
 class JSONProducer(object):
@@ -74,7 +75,7 @@
 
 class Events(service.BuildbotService):
 
-    EVENT_SERVER_ENDPOINT = b'https://ews.webkit.org/results/'
+    EVENT_SERVER_ENDPOINT = 'https://ews.webkit{}.org/results/'.format(custom_suffix).encode()
 
     def __init__(self, master_hostname, type_prefix='', name='Events'):
         """

Modified: trunk/Tools/CISupport/ews-build/master.cfg (288229 => 288230)


--- trunk/Tools/CISupport/ews-build/master.cfg	2022-01-19 20:21:54 UTC (rev 288229)
+++ trunk/Tools/CISupport/ews-build/master.cfg	2022-01-19 20:23:22 UTC (rev 288230)
@@ -30,6 +30,7 @@
 BuildStep.warn_deprecated_if_oldstyle_subclass = lambda self, name: None
 
 is_test_mode_enabled = load_password('BUILDBOT_PRODUCTION') is None
+custom_suffix = '-uat' if load_password('BUILDBOT_UAT') else ''
 
 c = BuildmasterConfig = {}
 
@@ -72,14 +73,14 @@
 
 c['protocols'] = {'pb': {'port': 17000}}
 
-c['projectName'] = 'WebKit EWS'
-c['projectURL'] = 'https://ews-build.webkit.org/'
+c['projectName'] = 'WebKit EWS{}'.format(custom_suffix.upper())
+c['projectURL'] = 'https://ews-build.webkit{}.org/'.format(custom_suffix)
 
 if is_test_mode_enabled:
     c['buildbotURL'] = 'http://localhost:8010/'
     c['db_url'] = 'sqlite:///state.sqlite?serialize_access=1'
 else:
-    c['buildbotURL'] = 'https://ews-build.webkit.org/'
+    c['buildbotURL'] = 'https://ews-build.webkit{}.org/'.format(custom_suffix)
     db_url = load_password('DB_URL', None)
     db_name = load_password('DB_NAME', None)
     db_username = load_password('DB_USERNAME', None)

Modified: trunk/Tools/CISupport/ews-build/send_email.py (288229 => 288230)


--- trunk/Tools/CISupport/ews-build/send_email.py	2022-01-19 20:21:54 UTC (rev 288229)
+++ trunk/Tools/CISupport/ews-build/send_email.py	2022-01-19 20:23:22 UTC (rev 288230)
@@ -28,10 +28,11 @@
 from email.mime.text import MIMEText
 
 is_test_mode_enabled = os.getenv('BUILDBOT_PRODUCTION') is None
+custom_suffix = '-uat' if os.getenv('BUILDBOT_UAT') else ''
 
 CURRENT_HOSTNAME = socket.gethostname().strip()
 EWS_BUILD_HOSTNAME = 'ews-build.webkit.org'
-FROM_EMAIL = 'e...@webkit.org'
+FROM_EMAIL = 'ews@webkit{}.org'.format(custom_suffix)
 IGALIA_JSC_QUEUES_PATTERNS = ['armv7', 'mips', 'i386']
 IGALIA_GTK_WPE_QUEUES_PATTERNS = ['gtk', 'wpe']
 SERVER = 'localhost'

Modified: trunk/Tools/CISupport/ews-build/steps.py (288229 => 288230)


--- trunk/Tools/CISupport/ews-build/steps.py	2022-01-19 20:21:54 UTC (rev 288229)
+++ trunk/Tools/CISupport/ews-build/steps.py	2022-01-19 20:23:22 UTC (rev 288230)
@@ -44,10 +44,11 @@
     print('ERROR: Please use Python 3. This code is not compatible with Python 2.')
     sys.exit(1)
 
+custom_suffix = '-uat' if os.getenv('BUILDBOT_UAT') else ''
 BUG_SERVER_URL = 'https://bugs.webkit.org/'
 COMMITS_INFO_URL = 'https://commits.webkit.org/'
 S3URL = 'https://s3-us-west-2.amazonaws.com/'
-S3_RESULTS_URL = 'https://ews-build.s3-us-west-2.amazonaws.com/'
+S3_RESULTS_URL = 'https://ews-build{}.s3-us-west-2.amazonaws.com/'.format(custom_suffix)
 CURRENT_HOSTNAME = socket.gethostname().strip()
 EWS_BUILD_HOSTNAME = 'ews-build.webkit.org'
 EWS_URL = 'https://ews.webkit.org/'
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to