[Releng] Update publish scripts
- Disable P2-Admin command (and composite-repo generation)
- Fix p2 repository unzip command
Change-Id: I9d5f360088cf585978e5484aa64e026a96a4b2a4
Signed-off-by: Camille Letavernier <cletavernier@eclipsesource.com>
diff --git a/compare/releng/scripts/common.sh b/compare/releng/scripts/common.sh
index 6c5dd45..f799ee6 100644
--- a/compare/releng/scripts/common.sh
+++ b/compare/releng/scripts/common.sh
@@ -78,7 +78,8 @@
exit -1
fi
-$SSH $sshGenie@$sshRemote chmod u+x $P2_ADMIN_PATH
+# FIXME This isn't permitted with the current CI infra. Composite repositories can't be updated with this function at the moment
+# $SSH $sshGenie@$sshRemote chmod u+x $P2_ADMIN_PATH
alias p2-admin="${JAVA_HOME}/bin/java -jar $P2_ADMIN_PATH/plugins/org.eclipse.equinox.launcher_*.jar"
alias composite-repository="p2-admin -application org.eclipselabs.equinox.p2.composite.repository -compressed"
diff --git a/compare/releng/scripts/publish-nightly.sh b/compare/releng/scripts/publish-nightly.sh
index bda0cb3..fc5b8cc 100755
--- a/compare/releng/scripts/publish-nightly.sh
+++ b/compare/releng/scripts/publish-nightly.sh
@@ -236,47 +236,50 @@
mkdir "tmp"
cd tmp
wget --no-check-certificate "https://ci.eclipse.org/papyrus/job/${JOB_NAME}/${REPOSITORY_PATH}/${ZIP_NAME}"
-unzip -t ${ZIP_NAME}
+mkdir "repository"
+unzip ${ZIP_NAME} -d "repository"
# Also publish a dump of the build environment, may be useful to debug
-env | sort > "./build_env.txt"
-$SCP -r * $sshGenie@$sshRemote:/$repoDir
+env | sort > "repository/build_env.txt"
+$SCP -r repository/* $sshGenie@$sshRemote:/$repoDir
cd ..
rm -r tmp
-echo "Adding $UPDATE_SITE_URL to composites repositories:"
+### FIXME Restore composite P2 repositories. p2-admin doesn't work with the current script
-# add a link for the $VERSION (e.g. "1.2.0" => "1.2.0-NYYYYMMDD-HHMM")
-echo " $PAPYRUS_COMPARE_UPDATES_BASE_URL/$BUILD_TYPE/$VERSION"
-composite-repository \
- -location "$repoDir" \
- -add "$UPDATE_SITE_URL" \
- -repositoryName "Papyrus Compare $VERSION $BUILD_TYPE builds"
-$SSH $sshGenie@$sshRemote createP2Index "$repoDir"
-
-# add a link for the $MINOR_STREAM (e.g. "1.2.x" => "1.2.0-NYYYYMMDD-HHMM")
-echo " $PAPYRUS_COMPARE_UPDATES_BASE_URL/$BUILD_TYPE/$MINOR_STREAM"
-composite-repository \
- -location "$BUILD_PATH/$MINOR_STREAM" \
- -add "$UPDATE_SITE_URL" \
- -repositoryName "Papyrus Compare $MINOR_STREAM $BUILD_TYPE builds"
-$SSH $sshGenie@$sshRemote createP2Index "$BUILD_PATH/$MINOR_STREAM"
-
-# add a link for the $MAJOR_STREAM (e.g. "1.x" => "1.2.0-NYYYYMMDD-HHMM")
-echo " $PAPYRUS_COMPARE_UPDATES_BASE_URL/$BUILD_TYPE/$MAJOR_STREAM"
-composite-repository \
- -location "$BUILD_PATH/$MAJOR_STREAM" \
- -add "$UPDATE_SITE_URL" \
- -repositoryName "Papyrus Compare $MAJOR_STREAM $BUILD_TYPE builds"
-$SSH $sshGenie@$sshRemote createP2Index "$BUILD_PATH/$MAJOR_STREAM"
-
-# add a link for all nightly list
-echo " $PAPYRUS_COMPARE_UPDATES_BASE_URL/$BUILD_TYPE"
-composite-repository \
- -location "$BUILD_PATH" \
- -add "$UPDATE_SITE_URL" \
- -repositoryName "Papyrus Compare $BUILD_TYPE builds"
-$SSH $sshGenie@$sshRemote createP2Index "$BUILD_PATH"
-
-# Setup or update the redirects (implemented as composite repos)
-echo "Redirecting 'latest' repositories to $UPDATE_SITE_URL:"
-$SSH $sshGenie@$sshRemote visitVersions "$BUILD_PATH" "updateLatestRedirections" $VERSION
+#echo "Adding $UPDATE_SITE_URL to composites repositories:"
+#
+## add a link for the $VERSION (e.g. "1.2.0" => "1.2.0-NYYYYMMDD-HHMM")
+#echo " $PAPYRUS_COMPARE_UPDATES_BASE_URL/$BUILD_TYPE/$VERSION"
+#composite-repository \
+# -location "$repoDir" \
+# -add "$UPDATE_SITE_URL" \
+# -repositoryName "Papyrus Compare $VERSION $BUILD_TYPE builds"
+#$SSH $sshGenie@$sshRemote createP2Index "$repoDir"
+#
+## add a link for the $MINOR_STREAM (e.g. "1.2.x" => "1.2.0-NYYYYMMDD-HHMM")
+#echo " $PAPYRUS_COMPARE_UPDATES_BASE_URL/$BUILD_TYPE/$MINOR_STREAM"
+#composite-repository \
+# -location "$BUILD_PATH/$MINOR_STREAM" \
+# -add "$UPDATE_SITE_URL" \
+# -repositoryName "Papyrus Compare $MINOR_STREAM $BUILD_TYPE builds"
+#$SSH $sshGenie@$sshRemote createP2Index "$BUILD_PATH/$MINOR_STREAM"
+#
+## add a link for the $MAJOR_STREAM (e.g. "1.x" => "1.2.0-NYYYYMMDD-HHMM")
+#echo " $PAPYRUS_COMPARE_UPDATES_BASE_URL/$BUILD_TYPE/$MAJOR_STREAM"
+#composite-repository \
+# -location "$BUILD_PATH/$MAJOR_STREAM" \
+# -add "$UPDATE_SITE_URL" \
+# -repositoryName "Papyrus Compare $MAJOR_STREAM $BUILD_TYPE builds"
+#$SSH $sshGenie@$sshRemote createP2Index "$BUILD_PATH/$MAJOR_STREAM"
+#
+## add a link for all nightly list
+#echo " $PAPYRUS_COMPARE_UPDATES_BASE_URL/$BUILD_TYPE"
+#composite-repository \
+# -location "$BUILD_PATH" \
+# -add "$UPDATE_SITE_URL" \
+# -repositoryName "Papyrus Compare $BUILD_TYPE builds"
+#$SSH $sshGenie@$sshRemote createP2Index "$BUILD_PATH"
+#
+## Setup or update the redirects (implemented as composite repos)
+#echo "Redirecting 'latest' repositories to $UPDATE_SITE_URL:"
+#$SSH $sshGenie@$sshRemote visitVersions "$BUILD_PATH" "updateLatestRedirections" $VERSION