diff options
author | Cédric Ollivier <cedric.ollivier@orange.com> | 2019-01-05 13:56:30 +0100 |
---|---|---|
committer | Cédric Ollivier <cedric.ollivier@orange.com> | 2019-01-05 13:56:30 +0100 |
commit | ab4b5a257813b172aebd409f68c6483d6383bb99 (patch) | |
tree | 58604bb889a8e7d11f98f20de57a7650629dd914 /jjb/functest | |
parent | 4678f51e158a647dd72647f7faca8353c067f4b0 (diff) |
Allow conditional docker build args
It allows managing xtesting and functest jjbs via the same role.
functest-component doesn't take BRANCH into account.
Change-Id: If487e8350bca6b37d585a4ed16214e77df6170ae
Signed-off-by: Cédric Ollivier <cedric.ollivier@orange.com>
Diffstat (limited to 'jjb/functest')
-rw-r--r-- | jjb/functest/xtesting.yaml | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/jjb/functest/xtesting.yaml b/jjb/functest/xtesting.yaml index 8e2b1e82c..267514a24 100644 --- a/jjb/functest/xtesting.yaml +++ b/jjb/functest/xtesting.yaml @@ -73,8 +73,13 @@ else image={repo}:{port}/{container}:{tag} fi + if [ "{ref_arg}" = "None" ]; then + build_arg="" + else + build_arg="--build-arg {ref_arg}={ref}" + fi cd {path} - sudo docker build --build-arg {ref_arg}={ref} \ + sudo docker build $build_arg \ --pull=false --no-cache --force-rm=true \ -t $image . |