Skip to content

Commit

Permalink
[BUILD] Modified Jenkinsfile to only delete builds for this version f…
Browse files Browse the repository at this point in the history
…rom the downloads page
  • Loading branch information
wes-johnson committed Jan 18, 2024
1 parent 6fcb7f2 commit 2f13209
Showing 1 changed file with 12 additions and 12 deletions.
24 changes: 12 additions & 12 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -49,26 +49,26 @@ spec:
[$class: 'StringBinding', credentialsId: 'gpg-passphrase', variable: 'KEYRING_PASSPHRASE']
]) {
sh '''
curl -o tck/build/hivemq-extension/sparkplug-tck-3.0.0-signed.jar -F file=@tck/build/hivemq-extension/sparkplug-tck-3.0.0.jar https://cbi.eclipse.org/jarsigner/sign
curl -o tck/build/hivemq-extension/sparkplug-tck-4.0.0-signed.jar -F file=@tck/build/hivemq-extension/sparkplug-tck-4.0.0.jar https://cbi.eclipse.org/jarsigner/sign
export GPG_TTY=/dev/console
gpg --batch --import "${KEYRING}"
for fpr in $(gpg --list-keys --with-colons | awk -F: \'/fpr:/ {print $10}\' | sort -u); do echo -e "5\ny\n" | gpg --batch --command-fd 0 --expert --edit-key ${fpr} trust; done
mkdir tck/build/hivemq-extension/working_tmp
cd tck/build/hivemq-extension/working_tmp
unzip ../sparkplug-tck-3.0.0.zip
mv ../sparkplug-tck-3.0.0-signed.jar sparkplug-tck/sparkplug-tck-3.0.0.jar
zip -r ../sparkplug-tck-3.0.0.zip sparkplug-tck
unzip ../sparkplug-tck-4.0.0.zip
mv ../sparkplug-tck-4.0.0-signed.jar sparkplug-tck/sparkplug-tck-4.0.0.jar
zip -r ../sparkplug-tck-4.0.0.zip sparkplug-tck
cd ..
gpg -v --no-tty --passphrase "${KEYRING_PASSPHRASE}" -c --batch sparkplug-tck-3.0.0.zip
gpg -v --no-tty --passphrase "${KEYRING_PASSPHRASE}" -c --batch sparkplug-tck-4.0.0.zip
echo "no-tty" >> ~/.gnupg/gpg.conf
gpg -vvv --no-permission-warning --output "sparkplug-tck-3.0.0.zip.sig" --batch --yes --pinentry-mode=loopback --passphrase="${KEYRING_PASSPHRASE}" --no-tty --detach-sig sparkplug-tck-3.0.0.zip
gpg -vvv --no-permission-warning --output "sparkplug-tck-4.0.0.zip.sig" --batch --yes --pinentry-mode=loopback --passphrase="${KEYRING_PASSPHRASE}" --no-tty --detach-sig sparkplug-tck-4.0.0.zip
cd ../../
./package.sh
gpg -vvv --no-permission-warning --output "Eclipse-Sparkplug-TCK-3.0.0.zip.sig" --batch --yes --pinentry-mode=loopback --passphrase="${KEYRING_PASSPHRASE}" --no-tty --detach-sig Eclipse-Sparkplug-TCK-3.0.0.zip
gpg -vvv --verify Eclipse-Sparkplug-TCK-3.0.0.zip.sig
gpg -vvv --no-permission-warning --output "Eclipse-Sparkplug-TCK-4.0.0.zip.sig" --batch --yes --pinentry-mode=loopback --passphrase="${KEYRING_PASSPHRASE}" --no-tty --detach-sig Eclipse-Sparkplug-TCK-4.0.0.zip
gpg -vvv --verify Eclipse-Sparkplug-TCK-4.0.0.zip.sig
'''
}
}
Expand All @@ -78,10 +78,10 @@ spec:
steps {
sshagent(credentials: ['projects-storage.eclipse.org-bot-ssh']) {
sh '''
ssh -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -o BatchMode=yes [email protected] rm -rf /home/data/httpd/download.eclipse.org/sparkplug/*
ssh -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -o BatchMode=yes [email protected] mkdir -p /home/data/httpd/download.eclipse.org/sparkplug/3.0.0
scp -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -o BatchMode=yes tck/Eclipse-Sparkplug-TCK-3.0.0.zip [email protected]:/home/data/httpd/download.eclipse.org/sparkplug/3.0.0/
scp -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -o BatchMode=yes tck/Eclipse-Sparkplug-TCK-3.0.0.zip.sig [email protected]:/home/data/httpd/download.eclipse.org/sparkplug/3.0.0/
ssh -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -o BatchMode=yes [email protected] rm -rf /home/data/httpd/download.eclipse.org/sparkplug/4.0.0/*
ssh -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -o BatchMode=yes [email protected] mkdir -p /home/data/httpd/download.eclipse.org/sparkplug/4.0.0
scp -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -o BatchMode=yes tck/Eclipse-Sparkplug-TCK-4.0.0.zip [email protected]:/home/data/httpd/download.eclipse.org/sparkplug/4.0.0/
scp -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -o BatchMode=yes tck/Eclipse-Sparkplug-TCK-4.0.0.zip.sig [email protected]:/home/data/httpd/download.eclipse.org/sparkplug/4.0.0/
'''
}
}
Expand Down

0 comments on commit 2f13209

Please sign in to comment.