Skip to content

Commit f2ffe33

Browse files
committed
revert(script): jmx exporter source upload back to jar upload
Reverts a single file from #687 which should have been done in #933. [Slack discussion](https://stackable-workspace.slack.com/archives/C02FZ581UCD/p1738149918664689)
1 parent 82591c6 commit f2ffe33

File tree

1 file changed

+3
-11
lines changed

1 file changed

+3
-11
lines changed

.scripts/upload_new_jmx_exporter_version.sh

+3-11
Original file line numberDiff line numberDiff line change
@@ -23,28 +23,20 @@ fi
2323

2424
# deletes the temp directory
2525
function cleanup {
26-
rm -rf "$WORK_DIR"
26+
rm -rf "$WORK_DIR"
2727
}
2828

2929
# register the cleanup function to be called on the EXIT signal
3030
trap cleanup EXIT
3131

3232
cd "$WORK_DIR" || exit
3333

34-
src_file=jmx_prometheus-$VERSION-src.tar.gz
35-
3634
# JMX Exporter does not currently publish signatures or SBOMs (as of 2023-07-24, latest version at this point 0.19.0)
3735
echo "Downloading JMX Exporter"
38-
# JMX Exporter provides no offficial source tarballs, download from Git
39-
git clone https://github.com/prometheus/jmx_exporter "jmx_prometheus-${VERSION}" "--branch=${VERSION}" --depth=1
40-
41-
echo "Archiving JMX Exporter"
42-
git -C "jmx_prometheus-${VERSION}" archive "${VERSION}" --format=tar.gz --prefix="jmx_prometheus-${VERSION}-src/" > "${src_file}"
43-
sha256sum "${src_file}" | cut --delimiter=' ' --field=1 > "${src_file}.sha256"
36+
curl --fail -LOs "https://repo1.maven.org/maven2/io/prometheus/jmx/jmx_prometheus_javaagent/$VERSION/jmx_prometheus_javaagent-$VERSION.jar"
4437

4538
echo "Uploading to Nexus"
46-
curl --fail -u "$NEXUS_USER:$NEXUS_PASSWORD" --upload-file "${src_file}" 'https://repo.stackable.tech/repository/packages/jmx-exporter/'
47-
curl --fail -u "$NEXUS_USER:$NEXUS_PASSWORD" --upload-file "${src_file}.sha256" 'https://repo.stackable.tech/repository/packages/jmx-exporter/'
39+
curl --fail -u "$NEXUS_USER:$NEXUS_PASSWORD" --upload-file "jmx_prometheus_javaagent-$VERSION.jar" 'https://repo.stackable.tech/repository/packages/jmx-exporter/'
4840

4941
echo "Successfully uploaded new version of JMX Exporter ($VERSION) to Nexus"
5042
echo "https://repo.stackable.tech/service/rest/repository/browse/packages/jmx-exporter/"

0 commit comments

Comments
 (0)