Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Williams2013-06-07 00:51:01 -0400
committerDavid Williams2013-06-07 00:51:01 -0400
commit9d4fde022dc8d7e05a4d6488cded7551be84e0f4 (patch)
tree9e1479345e570bf663d63f15142a9bb9a977b030
parent7fc06882342bdafd06280aa8601e8518ec0cef34 (diff)
downloadeclipse.platform.releng.aggregator-9d4fde022dc8d7e05a4d6488cded7551be84e0f4.tar.gz
eclipse.platform.releng.aggregator-9d4fde022dc8d7e05a4d6488cded7551be84e0f4.tar.xz
eclipse.platform.releng.aggregator-9d4fde022dc8d7e05a4d6488cded7551be84e0f4.zip
Bug 403538 - Improve templates and rename scripts
-rwxr-xr-xproduction/sdk/promoteKepler/addRepoProperties.sh4
-rwxr-xr-xproduction/sdk/promoteKepler/promoteDropSite.sh21
-rwxr-xr-xproduction/sdk/promoteKepler/promoteDropSiteEq.sh19
-rwxr-xr-xproduction/sdk/promoteKepler/promoteRepo.sh34
-rwxr-xr-xproduction/sdk/promoteKepler/promoteSites.sh32
5 files changed, 78 insertions, 32 deletions
diff --git a/production/sdk/promoteKepler/addRepoProperties.sh b/production/sdk/promoteKepler/addRepoProperties.sh
index e2b07f37..37c9d853 100755
--- a/production/sdk/promoteKepler/addRepoProperties.sh
+++ b/production/sdk/promoteKepler/addRepoProperties.sh
@@ -48,8 +48,8 @@ else
MIRRORURL_ARG=""
fi
-ART_REPO_NAME="Eclipse Project Artifacts Repository for Kepler"
-CON_REPO_NAME="Eclipse Project Metadata Repository for Kepler"
+ART_REPO_NAME="Eclipse Project Repository for Kepler"
+CON_REPO_NAME="Eclipse Project Repository for Kepler"
MIRRORS_URL_ARG="-Dp2MirrorsURL=${MIRRORURL_ARG}"
ART_REPO_ARG="-DartifactRepoDirectory=${REPO}"
diff --git a/production/sdk/promoteKepler/promoteDropSite.sh b/production/sdk/promoteKepler/promoteDropSite.sh
index cea368dd..a7526994 100755
--- a/production/sdk/promoteKepler/promoteDropSite.sh
+++ b/production/sdk/promoteKepler/promoteDropSite.sh
@@ -2,23 +2,23 @@
DROP_ID=$1
DL_LABEL=$2
+HIDE_SITE=$3
function usage ()
{
- printf "\n\tUsage: %s DROP_ID DL_LABEL " $(basename $0) >&2
+ printf "\n\tUsage: %s DROP_ID DL_LABEL HIDE_SITE" $(basename $0) >&2
printf "\n\t\t%s\t%s" "DROP_ID " "such as I20121031-2000." >&2
printf "\n\t\t%s\t%s" "DL_LABEL " "such as 4.3M3." >&2
+ printf "\n\t\t%s\t%s" "HIDE_SITE " "true or false." >&2
}
-if [[ -z "${DROP_ID}" || -z "${DL_LABEL}" ]]
+if [[ -z "${DROP_ID}" || -z "${DL_LABEL}" || -z "${HIDE_SITE}" ]]
then
printf "\n\n\t%s\n\n" "ERROR: arguments missing in call to $( basename $0 )" >&2
usage
exit 1
fi
-DL_TYPE=S
-BUILD_TIMESTAMP=${DROP_ID//[MI-]/}
DL_DROP_ID=${DL_TYPE}-${DL_LABEL}-${BUILD_TIMESTAMP}
cd /shared/eclipse/builds/4I/siteDir/eclipse/downloads/drops4
@@ -40,7 +40,18 @@ rm renameBuild.sh
# keep hidden, initially, both to confirm all is correct,
# and in theory could wait a bit to get a mirror or two
# (in some cases).
-touch ${DL_DROP_ID}/buildHidden
+if [[ "${HIDE_SITE}" == "true" ]]
+then
+ touch ${DL_DROP_ID}/buildHidden
+ if [[ $? != 0 ]]
+ then
+ echo "touch failed. Exiting."
+ exit 1
+ fi
+ echo "Remember to remove 'buildHidden' file, and re-run updateIndexes.sh since HIDE_SITE was ${HIDE_SITE}." >> "${CL_SITE}/checklist.txt"
+else
+ echo "HIDE_SITE value was ${HIDE_SITE}"
+fi
printf "\n\t%s\n" "rsync to downloads."
# Here we can rsync with committer id. For Equinox, we have to create a promotion file.
diff --git a/production/sdk/promoteKepler/promoteDropSiteEq.sh b/production/sdk/promoteKepler/promoteDropSiteEq.sh
index 0dced432..842ff87b 100755
--- a/production/sdk/promoteKepler/promoteDropSiteEq.sh
+++ b/production/sdk/promoteKepler/promoteDropSiteEq.sh
@@ -2,23 +2,23 @@
DROP_ID=$1
DL_LABEL=$2
+HIDE_SITE=$3
function usage ()
{
- printf "\n\tUsage: %s DROP_ID DL_LABEL " $(basename $0) >&2
+ printf "\n\tUsage: %s DROP_ID DL_LABEL HIDE_SITE" $(basename $0) >&2
printf "\n\t\t%s\t%s" "DROP_ID " "such as I20121031-2000." >&2
printf "\n\t\t%s\t%s" "DL_LABEL " "such as KeplerM3." >&2
+ printf "\n\t\t%s\t%s" "HIDE_SITE " "true or false." >&2
}
-if [[ -z "${DROP_ID}" || -z "${DL_LABEL}" ]]
+if [[ -z "${DROP_ID}" || -z "${DL_LABEL}" || -z "${HIDE_SITE}" ]]
then
printf "\n\n\t%s\n\n" "ERROR: arguments missing in call to $( basename $0 )" >&2
usage
exit 1
fi
-DL_TYPE=S
-BUILD_TIMESTAMP=${DROP_ID//[MI-]/}
DL_DROP_ID=${DL_TYPE}-${DL_LABEL}-${BUILD_TIMESTAMP}
cd /shared/eclipse/builds/4I/siteDir/equinox/drops
@@ -37,10 +37,17 @@ mv ${DROP_ID}ORIG ${DROP_ID}
rm renameBuild.sh
+PROMOTE_PREFIX="promote"
+if [[ "${HIDE_SITE}" == "true" ]]
+then
+ PROMOTE_PREFIX="manual"
+ echo "Remember to change Equinox promote script name from 'manual-' to 'promote-' when time to promote." >> "${CL_SITE}/checklist.txt"
+fi
+
printf "\n\t%s\n" "Creating promote script."
echo "rsync -r /shared/eclipse/builds/4I/siteDir/equinox/drops/${DL_DROP_ID} /home/data/httpd/download.eclipse.org/equinox/drops/" \
- > /shared/eclipse/equinox/promotion/queue/promote-${DL_LABEL}.sh
+ > /shared/eclipse/equinox/promotion/queue/${PROMOTE_PREFIX}-${DL_LABEL}.sh
printf "\n\t%s\n" "Make sure promote script is 'executable'."
-chmod +x /shared/eclipse/equinox/promotion/queue/promote-${DL_LABEL}.sh
+chmod +x /shared/eclipse/equinox/promotion/queue/${PROMOTE_PREFIX}-${DL_LABEL}.sh
diff --git a/production/sdk/promoteKepler/promoteRepo.sh b/production/sdk/promoteKepler/promoteRepo.sh
index b982e386..05180842 100755
--- a/production/sdk/promoteKepler/promoteRepo.sh
+++ b/production/sdk/promoteKepler/promoteRepo.sh
@@ -1,31 +1,34 @@
#!/usr/bin/env bash
-DROP_SITE_ID=$1
+DROP_ID=$1
DL_LABEL=$2
+REPO_SITE_SEGMENT=$3
+HIDE_SITE=$4
function usage ()
{
- printf "\n\tUsage: %s DROP_SITE_ID DL_LABEL " $(basename $0) >&2
- printf "\n\t\t%s\t%s" "DROP_SITE_ID " "such as I20121031-2000." >&2
+ printf "\n\tUsage: %s DROP_ID DL_LABEL REPO_SITE_SEGMENT HIDE_SITE" $(basename $0) >&2
+ printf "\n\t\t%s\t%s" "DROP_ID " "such as I20121031-2000." >&2
printf "\n\t\t%s\t%s" "DL_LABEL " "such as 4.3M3." >&2
+ printf "\n\t\t%s\t%s" "REPO_SITE_SEGMENT " "such as 4.3milestones, 4.3, etc." >&2
+ printf "\n\t\t%s\t%s" "HIDE_SITE " "true or false." >&2
}
-if [[ -z "${DROP_SITE_ID}" || -z "${DL_LABEL}" ]]
+if [[ -z "${DROP_ID}" || -z "${DL_LABEL}" || -z "${REPO_SITE_SEGMENT}" || -z "${HIDE_SITE}" ]]
then
printf "\n\n\t%s\n\n" "ERROR: arguments missing in call to $( basename $0 )." >&2
usage
exit 1
fi
-DL_TYPE=S
-BUILD_TIMESTAMP=${DROP_SITE_ID//[MI-]/}
+
DL_SITE_ID=${DL_TYPE}-${DL_LABEL}-${BUILD_TIMESTAMP}
BUILDMACHINE_BASE_SITE=/shared/eclipse/builds/4I/siteDir/updates/4.3-I-builds
-BUILDMACHINE_SITE=${BUILDMACHINE_BASE_SITE}/${DROP_SITE_ID}
+BUILDMACHINE_SITE=${BUILDMACHINE_BASE_SITE}/${DROP_ID}
-DLMACHINE_BASE_SITE=/home/data/httpd/download.eclipse.org/eclipse/updates/4.3milestones
+DLMACHINE_BASE_SITE=/home/data/httpd/download.eclipse.org/eclipse/updates/${REPO_SITE_SEGMENT}
DLMACHINE_SITE=${DLMACHINE_BASE_SITE}/${DL_SITE_ID}
@@ -34,7 +37,7 @@ findEclipseExe ${DL_SITE_ID}
RC=$?
if [[ $RC == 0 ]]
then
- ./addRepoProperties.sh ${BUILDMACHINE_SITE} 4.3milestones ${DL_SITE_ID}
+./addRepoProperties.sh ${BUILDMACHINE_SITE} ${REPO_SITE_SEGMENT} ${DL_SITE_ID}
else
echo "ERROR: could not run add repo properties. Add manually."
fi
@@ -44,4 +47,15 @@ printf "\n\t%s\n" "rsync build machine repo site, to downloads repo site."
# contents to new directories contents
rsync -r "${BUILDMACHINE_SITE}/" "${DLMACHINE_SITE}"
-./runAntRunner.sh ${PWD}/addToComposite.xml addToComposite -Drepodir=${DLMACHINE_BASE_SITE} -Dcomplocation=${DL_SITE_ID}
+if [[ "${HIDE_SITE}" != "true" ]]
+then
+ ./runAntRunner.sh ${PWD}/addToComposite.xml addToComposite -Drepodir=${DLMACHINE_BASE_SITE} -Dcomplocation=${DL_SITE_ID}
+else
+ echo "#!/usr/bin/env bash" > deferedCompositeAdd.sh
+ echo "export JAVA_CMD=$JAVA_CMD" >> deferedCompositeAdd.sh
+ echo "export JAVA_EXEC_DIR=${JAVA_EXEC_DIR}" >> deferedCompositeAdd.sh
+ echo "export ECLIPSE_EXE=${ECLIPSE_EXE}" >> deferedCompositeAdd.sh
+ echo "./runAntRunner.sh ${PWD}/addToComposite.xml addToComposite -Drepodir=${DLMACHINE_BASE_SITE} -Dcomplocation=${DL_SITE_ID}" >> deferedCompositeAdd.sh
+ chmod +x deferedCompositeAdd.sh
+ echo "Remember to add to composite, deferedCompositeAdd.sh, since HIDE_SITE was ${HIDE_SITE}" >> "${CL_SITE}/checklist.txt"
+fi \ No newline at end of file
diff --git a/production/sdk/promoteKepler/promoteSites.sh b/production/sdk/promoteKepler/promoteSites.sh
index 5ee9c45d..1a28cb44 100755
--- a/production/sdk/promoteKepler/promoteSites.sh
+++ b/production/sdk/promoteKepler/promoteSites.sh
@@ -1,16 +1,30 @@
#!/usr/bin/env bash
-DROP_ID=I20130529-200
-DL_LABEL=4.3RC3
-DL_LABEL_EQ=KeplerRC3
+#DROP_ID=I20130605-2000
+DROP_ID=I20130605-1939
+DL_LABEL=4.3RC4
+DL_LABEL_EQ=KeplerRC4
+REPO_SITE_SEGMENT=4.3milestones
+#REPO_SITE_SEGMENT=4.3
+HIDE_SITE=true
+#HIDE_SITE=false
+export CL_SITE=${PWD}
+echo "CL_SITE: ${CL_SITE}"
+export DL_TYPE=S
+#export DL_TYPE=R
-printf "\n\n\t%s\t%s\n" "DROP_ID" "$DROP_ID"
-printf "\n\t%s\t%s\n" "DL_LABEL" "$DL_LABEL"
-printf "\n\t%s\t%s\n" "DL_LABEL_EQ" "$DL_LABEL_EQ"
+export BUILD_TIMESTAMP=${DROP_ID//[MI-]/}
+
+echo "Promoted: $( date )" > "${CL_SITE}/checklist.txt"
+printf "\n\t%s\t\t\t%s\n" "DROP_ID" "$DROP_ID" >> "${CL_SITE}/checklist.txt"
+printf "\n\t%s\t\t\t%s" "DL_LABEL" "$DL_LABEL" >> "${CL_SITE}/checklist.txt"
+printf "\n\t%s\t\t\t%s" "DL_LABEL_EQ" "$DL_LABEL_EQ" >> "${CL_SITE}/checklist.txt"
+printf "\n\t%s\t%s" "REPO_SITE_SEGMENT" "$REPO_SITE_SEGMENT" >> "${CL_SITE}/checklist.txt"
+printf "\n\t%s\t\t\t%s\n\n" "HIDE_SITE" "$HIDE_SITE" >> "${CL_SITE}/checklist.txt"
# we do Equinox first, since it has to wait in que until
# cronjob promotes it
-./promoteDropSiteEq.sh ${DROP_ID} ${DL_LABEL_EQ}
+./promoteDropSiteEq.sh ${DROP_ID} ${DL_LABEL_EQ} ${HIDE_SITE}
rccode=$?
if [[ $rccode != 0 ]]
then
@@ -18,7 +32,7 @@ then
exit $rccode
fi
-./promoteDropSite.sh ${DROP_ID} ${DL_LABEL}
+./promoteDropSite.sh ${DROP_ID} ${DL_LABEL} ${HIDE_SITE}
rccode=$?
if [[ $rccode != 0 ]]
then
@@ -27,7 +41,7 @@ then
fi
-./promoteRepo.sh ${DROP_ID} ${DL_LABEL}
+./promoteRepo.sh ${DROP_ID} ${DL_LABEL} ${REPO_SITE_SEGMENT} ${HIDE_SITE}
rccode=$?
if [[ $rccode != 0 ]]
then

Back to the top