]> gerrit.simantics Code Review - simantics/sysdyn.git/commitdiff
Fix build-installer to extract product before iscc run
authorTuukka Lehtonen <tuukka.lehtonen@semantum.fi>
Mon, 31 Aug 2020 06:56:02 +0000 (09:56 +0300)
committerTuukka Lehtonen <tuukka.lehtonen@semantum.fi>
Mon, 31 Aug 2020 06:56:02 +0000 (09:56 +0300)
gitlab #79

.gitlab-ci.yml

index 0e444fc0a11755b70bdd4631ca333821ab8d644f..a6d6afdb83c17d6fe799c4c925be00e2bc0777b8 100644 (file)
@@ -7,6 +7,7 @@ variables:
   PUBLISH_ADDRESS: www.simantics.org
   PUBLISH_P2_DIR: "/var/www/http-www.simantics.org/download/${CI_COMMIT_REF_NAME}/sysdyn/p2.site"
   PUBLISH_PRODUCT_DIR: "/var/www/http-www.simantics.org/download/${CI_COMMIT_REF_NAME}/sysdyn/products"
+  ZIP_FILE_NAME: "Simantics-Sysdyn-win64.zip"
 
 image: registry.simupedia.com/ci-images/maven-eclipse-adoptopenjdk-11:latest
 
@@ -40,15 +41,12 @@ review:
 build:
   stage: build
   script:
-    - export
-    - echo "${PUBLISH_P2_DIR}"
-    - echo "${PUBLISH_PRODUCT_DIR}"
     - mvn ${MAVEN_CLI_OPTS} -B clean verify -Dbuild-products=true
     - curl -s http://www.simantics.org/download/jre/$BUNDLED_JRE_VERSION.zip -o $BUNDLED_JRE_VERSION.zip
     - 7z x -bd $BUNDLED_JRE_VERSION.zip
     - rm $BUNDLED_JRE_VERSION.zip
     - export UNPACKED_PRODUCT_DIR=releng/org.simantics.sysdyn.rcp.product/target/products/Simantics-Sysdyn/win32/win32/x86_64
-    - export ZIP_PATH=${CI_PROJECT_DIR}/Simantics-Sysdyn-win64.zip
+    - export ZIP_PATH=${CI_PROJECT_DIR}/${ZIP_FILE_NAME}
     - mv $BUNDLED_JRE_VERSION/win32.x86_64 $UNPACKED_PRODUCT_DIR/simantics-sysdyn/jre
     - pushd ${UNPACKED_PRODUCT_DIR}
     - 7z a -bd -tzip "${ZIP_PATH}" simantics-sysdyn > /dev/null
@@ -68,12 +66,10 @@ publish:
   before_script:
     - *initialize_ssh_connection
   script:
-    - echo "${PUBLISH_P2_DIR}"
-    - echo "${PUBLISH_PRODUCT_DIR}"
-    #- ssh -i $GITLAB_PRIVATE_KEY $GITLAB_USERNAME@$PUBLISH_ADDRESS mkdir -p "${PUBLISH_P2_DIR}"
-    #- ssh -i $GITLAB_PRIVATE_KEY $GITLAB_USERNAME@$PUBLISH_ADDRESS mkdir -p "${PUBLISH_PRODUCT_DIR}"
-    #- rsync -e "ssh -i $GITLAB_PRIVATE_KEY" -v releng/org.simantics.sysdyn.repository/target/repository/* $GITLAB_USERNAME@$PUBLISH_ADDRESS:${PUBLISH_P2_DIR}/
-    #- rsync -e "ssh -i $GITLAB_PRIVATE_KEY" -v *.zip $GITLAB_USERNAME@$PUBLISH_ADDRESS:${PUBLISH_PRODUCT_DIR}/
+    - ssh -i $GITLAB_PRIVATE_KEY $GITLAB_USERNAME@$PUBLISH_ADDRESS mkdir -p "${PUBLISH_P2_DIR}"
+    - ssh -i $GITLAB_PRIVATE_KEY $GITLAB_USERNAME@$PUBLISH_ADDRESS mkdir -p "${PUBLISH_PRODUCT_DIR}"
+    - rsync -e "ssh -i $GITLAB_PRIVATE_KEY" -v releng/org.simantics.sysdyn.repository/target/repository/* $GITLAB_USERNAME@$PUBLISH_ADDRESS:${PUBLISH_P2_DIR}/
+    - rsync -e "ssh -i $GITLAB_PRIVATE_KEY" -v *.zip $GITLAB_USERNAME@$PUBLISH_ADDRESS:${PUBLISH_PRODUCT_DIR}/
   rules:
     - if: '$CI_COMMIT_BRANCH == "master" || $CI_COMMIT_BRANCH =~ /^(release|feature|private)\/.*$/ || $CI_COMMIT_TAG =~ /^v.*$/'
       when: on_success
@@ -84,7 +80,8 @@ build-installer:
   image: docker:dind
   needs: [build]
   script:
-    - pushd releng/inno-setup
+    - cd releng/inno-setup
+    - unzip ${CI_PROJECT_DIR}/${ZIP_FILE_NAME} -d . 
     - docker run --rm -i -v $PWD:/work amake/innosetup sysdyn.iss
     - mv output/*.exe ${CI_PROJECT_DIR}/
   tags: