From 9f65834ede3dc27716ff0de154a23551d155dc18 Mon Sep 17 00:00:00 2001 From: Corentin LABBE Date: Thu, 2 May 2019 12:01:38 +0200 Subject: utils/agljobtemplate.py: Fix APPURL generation The generated APPURL was invalid: - it needed to be always using ci - it missed branch and arches path This patch move the generation of the application url in the jinja file for accessing the new sdk_arch Bug-AGL: SPEC-1850 Change-Id: Ie3ffff5f6181fdc89c3ebbd41078e4d60a06992b Signed-off-by: Corentin LABBE --- utils/agljobtemplate.py | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) (limited to 'utils/agljobtemplate.py') diff --git a/utils/agljobtemplate.py b/utils/agljobtemplate.py index e18e10f..90ff82c 100644 --- a/utils/agljobtemplate.py +++ b/utils/agljobtemplate.py @@ -136,20 +136,21 @@ class Agljobtemplate(object): if applications_url is None: app_url_base = '' - for section in defaults: + # WGT will be always uploaded in ci + appdefaults, appinfra = parse_cfg_file(self._template_path, 'default.cfg', 'ci') + for section in appdefaults: if section[0] == "urlbase": app_url_base = section[1] - app_url_fragment = '' - - if app_changeid is not None: - app_url_fragment += app_changeid + '/' + app_patchset - applications_url = urlparse.urljoin(app_url_base, app_url_fragment) + job['app_changeid'] = app_changeid + job['app_patchset'] = app_patchset + job['app_url_base'] = app_url_base + job['APPURL'] = 'automatic' + else: + job['APPURL'] = applications_url device_tags = ' '.join(device_tags) job['DEVICE_TAGS'] = device_tags - if applications_url is not None: - job['APPURL'] = applications_url test_templates = [] # If the user doesn't specify tests, use the default ones from the build-type -- cgit 1.2.3-korg