diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 7c98241b67c06385974b44919f0f92fefb24f28c..3184e37390aecbe0097c98c4975afd3b75c3797c 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -15,6 +15,8 @@ variables: SKIP_DEPENDENCIES: "false" AUTO_DEPLOY_TO_PRODUCTION: "false" + MAVEN_LOCAL_DISTRIBUTION_REPOSITORY_DIR: "/tmp/maven_repository" + MAVEN_LOCAL_DISTRIBUTION_REPOSITORY_PRJ_DIR: "${MAVEN_LOCAL_DISTRIBUTION_REPOSITORY_DIR}/CHESS" stages: - build_sde @@ -53,12 +55,16 @@ maven_build_and_test: only: refs: - master - + variables: + MAVEN_LOCAL_DISTRIBUTION_PRJ_REPOSITORY_URL: "file://$MAVEN_LOCAL_DISTRIBUTION_REPOSITORY_PRJ_DIR" + stage: test environment: staging script: + #- mkdir -p MAVEN_LOCAL_DISTRIBUTION_REPOSITORY_DIR + #- "export DISPLAY=:0.0; cd org.polarsys.chess.parent; mvn $MAVEN_CLI_OPTS -P Neon-Java8,DevelopmentUpdateSite -Ddistribution.repository=$MAVEN_LOCAL_DISTRIBUTION_PRJ_REPOSITORY_URL clean deploy" - "export DISPLAY=:0.0; cd org.polarsys.chess.parent; mvn $MAVEN_CLI_OPTS -P Neon-Java8,DevelopmentUpdateSite clean install" - + .deploy_to_production_update_site: &deploy_to_production_update_site dependencies: - maven_build_and_test @@ -67,6 +73,7 @@ maven_build_and_test: UPDATE_SITE_MOUNT_DIR: "/tmp/www_ci" UPDATE_SITE_PROD_TARGET_DIR: "html/tools/aida_chess" REPOSITORY_TO_COPY: "org.polarsys.chess.parent/releng/eu.fbk.tools.aida.chess.repository/target/repository" + MAVEN_REPOSITORY_DIR: "html/tools/maven_repository" stage: deploy environment: staging @@ -77,6 +84,9 @@ maven_build_and_test: - mkdir -p $UPDATE_SITE_MOUNT_DIR/$UPDATE_SITE_PROD_TARGET_DIR - cp -r ${REPOSITORY_TO_COPY}/* $UPDATE_SITE_MOUNT_DIR/$UPDATE_SITE_PROD_TARGET_DIR - chmod -R 0777 $UPDATE_SITE_MOUNT_DIR/$UPDATE_SITE_PROD_TARGET_DIR + #- echo "Deploy to remote maven repository" + #- cp -r ${MAVEN_LOCAL_DISTRIBUTION_REPOSITORY_DIR}/* $UPDATE_SITE_MOUNT_DIR/$MAVEN_REPOSITORY_DIR + #- chmod -R 0777 $UPDATE_SITE_MOUNT_DIR/$MAVEN_REPOSITORY_DIR - fusermount -uz $UPDATE_SITE_MOUNT_DIR only: refs: diff --git a/org.polarsys.chess.parent/releng/org.polarsys.chess.configuration/pom.xml b/org.polarsys.chess.parent/releng/org.polarsys.chess.configuration/pom.xml index 93263ede6b81f41a7ffa4e3fe4352486d16ae096..ef02ae1dd89fd3edc974286829e79f1bf3d8b0f7 100644 --- a/org.polarsys.chess.parent/releng/org.polarsys.chess.configuration/pom.xml +++ b/org.polarsys.chess.parent/releng/org.polarsys.chess.configuration/pom.xml @@ -11,6 +11,7 @@ </prerequisites> <properties> + <distribution.repository>file:///tmp/maven_repository/</distribution.repository> <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding> @@ -23,9 +24,28 @@ <systemProperties></systemProperties> <tycho.testArgLine></tycho.testArgLine> <tycho.test.platformArgs /> - <tycho.test.jvmArgs>-Xmx512m ${tycho.test.platformArgs}</tycho.test.jvmArgs> - + <tycho.test.jvmArgs>-Xmx512m ${tycho.test.platformArgs}</tycho.test.jvmArgs> </properties> + + <distributionManagement> + <repository> + <id>CHESS</id> + <name>CHESS</name> + <url>${distribution.repository}</url> + </repository> + </distributionManagement> + + <repositories> + <repository> + <id>SDE</id> + <url>http://es-static.fbk.eu/tools/maven_repository/SDE</url> + </repository> + + <repository> + <id>EST</id> + <url>http://es-static.fbk.eu/tools/maven_repository/EST</url> + </repository> + </repositories> <build> <plugins>