From 1f6e0e79da2ca663b62ae3feb973b372dae1278a Mon Sep 17 00:00:00 2001 From: Miro Richard Eklund Date: Mon, 3 Sep 2018 12:20:42 +0300 Subject: [PATCH] Update jenkinsfile to define node as agent 'master' gitlab #28 Change-Id: I6ecf222ce6b15c95780bd59a7c60e8a918dd832c --- .../Jenkinsfile-sysdyn-simupedia-om | 107 +++++++++--------- 1 file changed, 53 insertions(+), 54 deletions(-) diff --git a/releng/JenkinsFiles/Jenkinsfile-sysdyn-simupedia-om b/releng/JenkinsFiles/Jenkinsfile-sysdyn-simupedia-om index 871f5d9e..6db9cae2 100644 --- a/releng/JenkinsFiles/Jenkinsfile-sysdyn-simupedia-om +++ b/releng/JenkinsFiles/Jenkinsfile-sysdyn-simupedia-om @@ -1,66 +1,65 @@ pipeline { - node('master') { - stages { - stage ('Build and possible publish product to web') { - bash '''#!/bin/bash - PKG=Simantics-Desktop-win32.win32.x86_64 - TGT=Simantics-Sysdyn-Simupedia-OM-win32.win32.x86_64 + agent { label 'master' } + stages { + stage ('Build and possible publish product to web') { + bash '''#!/bin/bash + PKG=Simantics-Desktop-win32.win32.x86_64 + TGT=Simantics-Sysdyn-Simupedia-OM-win32.win32.x86_64 - echo "Download current desktop product" - wget -nv http://www.simantics.org/download/${BRANCH}/${PKG}.zip + echo "Download current desktop product" + wget -nv http://www.simantics.org/download/${BRANCH}/${PKG}.zip - echo "Unzip Desktop product" - unzip -q -d ${PKG} ${PKG}.zip + echo "Unzip Desktop product" + unzip -q -d ${PKG} ${PKG}.zip - echo "Install sysdyn feature into unzipped product" - /opt/eclipse/eclipse -noSplash \ - -application org.eclipse.equinox.p2.director \ - -repository http://www.simantics.org/download/${BRANCH}/sysdyn/p2.site/ \ - -installIU fi.semantum.simupedia.documentserver.feature \ - -tag AddSysdyn \ - -destination ${PKG} \ - -profile DefaultProfile + echo "Install sysdyn feature into unzipped product" + /opt/eclipse/eclipse -noSplash \ + -application org.eclipse.equinox.p2.director \ + -repository http://www.simantics.org/download/${BRANCH}/sysdyn/p2.site/ \ + -installIU fi.semantum.simupedia.documentserver.feature \ + -tag AddSysdyn \ + -destination ${PKG} \ + -profile DefaultProfile - echo "Install simupedia documentserver feature into unzipped product" - /opt/eclipse/eclipse -noSplash \ - -application org.eclipse.equinox.p2.director \ - -repository https://www.simantics.org/update/simupedia/${BRANCH}/p2.site/ \ - -installIU fi.semantum.simupedia.documentserver.feature \ - -tag AddSimupediaSysdyn \ - -destination ${PKG} \ - -profile DefaultProfile + echo "Install simupedia documentserver feature into unzipped product" + /opt/eclipse/eclipse -noSplash \ + -application org.eclipse.equinox.p2.director \ + -repository https://www.simantics.org/update/simupedia/${BRANCH}/p2.site/ \ + -installIU fi.semantum.simupedia.documentserver.feature \ + -tag AddSimupediaSysdyn \ + -destination ${PKG} \ + -profile DefaultProfile - echo "Install simupedia documentserver feature into unzipped product" - /opt/eclipse/eclipse -noSplash \ - -application org.eclipse.equinox.p2.director \ - -repository https://www.simantics.org/update/simupedia-sysdyn/${BRANCH}/p2.site/ \ - -installIU fi.semantum.simupedia.simulation.sysdyn.feature \ - -tag AddSimupediaSimulationSysdyn} \ - -destination ${PKG} \ - -profile DefaultProfile + echo "Install simupedia documentserver feature into unzipped product" + /opt/eclipse/eclipse -noSplash \ + -application org.eclipse.equinox.p2.director \ + -repository https://www.simantics.org/update/simupedia-sysdyn/${BRANCH}/p2.site/ \ + -installIU fi.semantum.simupedia.simulation.sysdyn.feature \ + -tag AddSimupediaSimulationSysdyn} \ + -destination ${PKG} \ + -profile DefaultProfile - echo "Install open modelica" - /opt/eclipse/eclipse -noSplash \ - -application org.eclipse.equinox.p2.director \ - -repository http://www.simantics.org/download/master/openmodelica/p2.site/ \ - -installIU org.simantics.om.feature \ - -tag AddOpenModelica \ - -destination ${PKG} \ - -profile DefaultProfile + echo "Install open modelica" + /opt/eclipse/eclipse -noSplash \ + -application org.eclipse.equinox.p2.director \ + -repository http://www.simantics.org/download/master/openmodelica/p2.site/ \ + -installIU org.simantics.om.feature \ + -tag AddOpenModelica \ + -destination ${PKG} \ + -profile DefaultProfile - echo "Re-package as SimanticsSysdynSimupediaOM.product" - mv -v ${PKG} ${TGT} - 7z a -tzip ${TGT}.zip ${TGT} > /dev/null - rm -rf ${PKG}.zip ${TGT} + echo "Re-package as SimanticsSysdynSimupediaOM.product" + mv -v ${PKG} ${TGT} + 7z a -tzip ${TGT}.zip ${TGT} > /dev/null + rm -rf ${PKG}.zip ${TGT} - if [ -n "${PUBLISH_PRODUCTS}" ]; then - PRODUCT_PUBLISH_DIR=/var/www/http-www.simantics.org/download/${BRANCH}/sysdyn/products - echo "Publishing product archives at: ${PRODUCT_PUBLISH_DIR}" - mkdir -p ${PRODUCT_PUBLISH_DIR} - rsync --stats --verbose --recursive --delete ${WORKSPACE}/*.zip ${PRODUCT_PUBLISH_DIR} - fi - ''' - } + if [ -n "${PUBLISH_PRODUCTS}" ]; then + PRODUCT_PUBLISH_DIR=/var/www/http-www.simantics.org/download/${BRANCH}/sysdyn/products + echo "Publishing product archives at: ${PRODUCT_PUBLISH_DIR}" + mkdir -p ${PRODUCT_PUBLISH_DIR} + rsync --stats --verbose --recursive --delete ${WORKSPACE}/*.zip ${PRODUCT_PUBLISH_DIR} + fi + ''' } } } \ No newline at end of file -- 2.47.1