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
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
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
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: