From 3dac94afd112e6cd60bff91d106cda936b619aa6 Mon Sep 17 00:00:00 2001 From: Andrew Azores Date: Mon, 16 Sep 2024 16:48:11 -0400 Subject: [PATCH 1/5] chore(jdk): upgrade to JDK21 on UBI9 --- compose/cryostat_docker.yml | 2 +- compose/cryostat_k8s.yml | 2 +- pom.xml | 2 +- src/main/docker/Dockerfile.jvm | 4 ++-- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/compose/cryostat_docker.yml b/compose/cryostat_docker.yml index 2ae890388..44a174dc1 100644 --- a/compose/cryostat_docker.yml +++ b/compose/cryostat_docker.yml @@ -34,7 +34,7 @@ services: CRYOSTAT_DISCOVERY_JDP_ENABLED: "true" JAVA_OPTS_APPEND: >- -XX:+FlightRecorder - -XX:StartFlightRecording=name=onstart,settings=default,disk=true,maxage=5m + -XX:StartFlightRecording=filename=/tmp,name=onstart,settings=default,disk=true,maxage=5m -Dcom.sun.management.jmxremote.autodiscovery=true -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=9091 diff --git a/compose/cryostat_k8s.yml b/compose/cryostat_k8s.yml index c104c8fd9..53b9d1ee1 100644 --- a/compose/cryostat_k8s.yml +++ b/compose/cryostat_k8s.yml @@ -19,7 +19,7 @@ services: environment: CRYOSTAT_DISCOVERY_PODMAN_ENABLED: "false" CRYOSTAT_DISCOVERY_JDP_ENABLED: "true" - JAVA_OPTS_APPEND: "-XX:+FlightRecorder -XX:StartFlightRecording=name=onstart,settings=default,disk=true,maxage=5m -Dcom.sun.management.jmxremote.autodiscovery=true -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=9091 -Dcom.sun.management.jmxremote.rmi.port=9091 -Djava.rmi.server.hostname=127.0.0.1 -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.local.only=false" + JAVA_OPTS_APPEND: "-XX:+FlightRecorder -XX:StartFlightRecording=filename=/tmp,name=onstart,settings=default,disk=true,maxage=5m -Dcom.sun.management.jmxremote.autodiscovery=true -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=9091 -Dcom.sun.management.jmxremote.rmi.port=9091 -Djava.rmi.server.hostname=127.0.0.1 -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.local.only=false" restart: always healthcheck: test: curl --fail http://localhost:8181/health/liveness || exit 1 diff --git a/pom.xml b/pom.xml index c650a5cd5..6211742a3 100644 --- a/pom.xml +++ b/pom.xml @@ -325,7 +325,7 @@ - -Dcryostat.discovery.jdp.enabled=true -Dcryostat.discovery.podman.enabled=true -XX:+FlightRecorder -XX:StartFlightRecording=filename/tmp,=name=onstart,settings=default,disk=true,maxage=5m -Dcom.sun.management.jmxremote.autodiscovery=true -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=9091 -Dcom.sun.management.jmxremote.rmi.port=9091 -Djava.rmi.server.hostname=127.0.0.1 -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.local.only=false + -Dcryostat.discovery.jdp.enabled=true -Dcryostat.discovery.podman.enabled=true -XX:+FlightRecorder -XX:StartFlightRecording=filename=/tmp/,name=onstart,settings=default,disk=true,maxage=5m -Dcom.sun.management.jmxremote.autodiscovery=true -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=9091 -Dcom.sun.management.jmxremote.rmi.port=9091 -Djava.rmi.server.hostname=127.0.0.1 -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.local.only=false diff --git a/src/main/docker/Dockerfile.jvm b/src/main/docker/Dockerfile.jvm index 1e2763863..497e4f1b3 100644 --- a/src/main/docker/Dockerfile.jvm +++ b/src/main/docker/Dockerfile.jvm @@ -77,7 +77,7 @@ # accessed directly. (example: "foo.example.com,bar.example.com") # ### -FROM registry.access.redhat.com/ubi8/openjdk-21-runtime:1.21-1.1733300818 +FROM registry.access.redhat.com/ubi9/openjdk-21-runtime:1.20-2.1725851019 ENV LANGUAGE='en_US:en' @@ -108,7 +108,7 @@ ENV SSL_TRUSTSTORE=$CONF_DIR/truststore.p12 \ USER root RUN mkdir -p $CONF_DIR \ && chmod -R g=u $CONF_DIR \ - && chown jboss:root $CONF_DIR + && chown default:root $CONF_DIR USER 185 RUN /deployments/app/truststore-setup.bash From 694cbcbc206ee7513c54098f91524ffab2207d1a Mon Sep 17 00:00:00 2001 From: Andrew Azores Date: Tue, 17 Sep 2024 16:16:58 -0400 Subject: [PATCH 2/5] revert to ubi8 --- compose/cryostat_docker.yml | 2 +- compose/cryostat_k8s.yml | 2 +- pom.xml | 2 +- src/main/docker/Dockerfile.jvm | 4 ++-- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/compose/cryostat_docker.yml b/compose/cryostat_docker.yml index 44a174dc1..2ae890388 100644 --- a/compose/cryostat_docker.yml +++ b/compose/cryostat_docker.yml @@ -34,7 +34,7 @@ services: CRYOSTAT_DISCOVERY_JDP_ENABLED: "true" JAVA_OPTS_APPEND: >- -XX:+FlightRecorder - -XX:StartFlightRecording=filename=/tmp,name=onstart,settings=default,disk=true,maxage=5m + -XX:StartFlightRecording=name=onstart,settings=default,disk=true,maxage=5m -Dcom.sun.management.jmxremote.autodiscovery=true -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=9091 diff --git a/compose/cryostat_k8s.yml b/compose/cryostat_k8s.yml index 53b9d1ee1..c104c8fd9 100644 --- a/compose/cryostat_k8s.yml +++ b/compose/cryostat_k8s.yml @@ -19,7 +19,7 @@ services: environment: CRYOSTAT_DISCOVERY_PODMAN_ENABLED: "false" CRYOSTAT_DISCOVERY_JDP_ENABLED: "true" - JAVA_OPTS_APPEND: "-XX:+FlightRecorder -XX:StartFlightRecording=filename=/tmp,name=onstart,settings=default,disk=true,maxage=5m -Dcom.sun.management.jmxremote.autodiscovery=true -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=9091 -Dcom.sun.management.jmxremote.rmi.port=9091 -Djava.rmi.server.hostname=127.0.0.1 -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.local.only=false" + JAVA_OPTS_APPEND: "-XX:+FlightRecorder -XX:StartFlightRecording=name=onstart,settings=default,disk=true,maxage=5m -Dcom.sun.management.jmxremote.autodiscovery=true -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=9091 -Dcom.sun.management.jmxremote.rmi.port=9091 -Djava.rmi.server.hostname=127.0.0.1 -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.local.only=false" restart: always healthcheck: test: curl --fail http://localhost:8181/health/liveness || exit 1 diff --git a/pom.xml b/pom.xml index 6211742a3..42259f534 100644 --- a/pom.xml +++ b/pom.xml @@ -325,7 +325,7 @@ - -Dcryostat.discovery.jdp.enabled=true -Dcryostat.discovery.podman.enabled=true -XX:+FlightRecorder -XX:StartFlightRecording=filename=/tmp/,name=onstart,settings=default,disk=true,maxage=5m -Dcom.sun.management.jmxremote.autodiscovery=true -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=9091 -Dcom.sun.management.jmxremote.rmi.port=9091 -Djava.rmi.server.hostname=127.0.0.1 -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.local.only=false + -Dcryostat.discovery.jdp.enabled=true -Dcryostat.discovery.podman.enabled=true -XX:+FlightRecorder -XX:StartFlightRecording=filename=name=onstart,settings=default,disk=true,maxage=5m -Dcom.sun.management.jmxremote.autodiscovery=true -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=9091 -Dcom.sun.management.jmxremote.rmi.port=9091 -Djava.rmi.server.hostname=127.0.0.1 -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.local.only=false diff --git a/src/main/docker/Dockerfile.jvm b/src/main/docker/Dockerfile.jvm index 497e4f1b3..46aa123bd 100644 --- a/src/main/docker/Dockerfile.jvm +++ b/src/main/docker/Dockerfile.jvm @@ -77,7 +77,7 @@ # accessed directly. (example: "foo.example.com,bar.example.com") # ### -FROM registry.access.redhat.com/ubi9/openjdk-21-runtime:1.20-2.1725851019 +FROM registry.access.redhat.com/ubi8/openjdk-21-runtime:1.20-2.1724181173 ENV LANGUAGE='en_US:en' @@ -108,7 +108,7 @@ ENV SSL_TRUSTSTORE=$CONF_DIR/truststore.p12 \ USER root RUN mkdir -p $CONF_DIR \ && chmod -R g=u $CONF_DIR \ - && chown default:root $CONF_DIR + && chown jboss:root $CONF_DIR USER 185 RUN /deployments/app/truststore-setup.bash From 4ba1c0a8cc9bb3dffb5acdaf307093280d4bb50c Mon Sep 17 00:00:00 2001 From: Andrew Azores Date: Tue, 17 Sep 2024 16:17:59 -0400 Subject: [PATCH 3/5] Revert "revert to ubi8" This reverts commit 53621a6a3e8c8a64cee650a3c89e5589e6801b30. --- compose/cryostat_docker.yml | 2 +- compose/cryostat_k8s.yml | 2 +- pom.xml | 2 +- src/main/docker/Dockerfile.jvm | 4 ++-- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/compose/cryostat_docker.yml b/compose/cryostat_docker.yml index 2ae890388..44a174dc1 100644 --- a/compose/cryostat_docker.yml +++ b/compose/cryostat_docker.yml @@ -34,7 +34,7 @@ services: CRYOSTAT_DISCOVERY_JDP_ENABLED: "true" JAVA_OPTS_APPEND: >- -XX:+FlightRecorder - -XX:StartFlightRecording=name=onstart,settings=default,disk=true,maxage=5m + -XX:StartFlightRecording=filename=/tmp,name=onstart,settings=default,disk=true,maxage=5m -Dcom.sun.management.jmxremote.autodiscovery=true -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=9091 diff --git a/compose/cryostat_k8s.yml b/compose/cryostat_k8s.yml index c104c8fd9..53b9d1ee1 100644 --- a/compose/cryostat_k8s.yml +++ b/compose/cryostat_k8s.yml @@ -19,7 +19,7 @@ services: environment: CRYOSTAT_DISCOVERY_PODMAN_ENABLED: "false" CRYOSTAT_DISCOVERY_JDP_ENABLED: "true" - JAVA_OPTS_APPEND: "-XX:+FlightRecorder -XX:StartFlightRecording=name=onstart,settings=default,disk=true,maxage=5m -Dcom.sun.management.jmxremote.autodiscovery=true -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=9091 -Dcom.sun.management.jmxremote.rmi.port=9091 -Djava.rmi.server.hostname=127.0.0.1 -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.local.only=false" + JAVA_OPTS_APPEND: "-XX:+FlightRecorder -XX:StartFlightRecording=filename=/tmp,name=onstart,settings=default,disk=true,maxage=5m -Dcom.sun.management.jmxremote.autodiscovery=true -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=9091 -Dcom.sun.management.jmxremote.rmi.port=9091 -Djava.rmi.server.hostname=127.0.0.1 -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.local.only=false" restart: always healthcheck: test: curl --fail http://localhost:8181/health/liveness || exit 1 diff --git a/pom.xml b/pom.xml index 42259f534..6211742a3 100644 --- a/pom.xml +++ b/pom.xml @@ -325,7 +325,7 @@ - -Dcryostat.discovery.jdp.enabled=true -Dcryostat.discovery.podman.enabled=true -XX:+FlightRecorder -XX:StartFlightRecording=filename=name=onstart,settings=default,disk=true,maxage=5m -Dcom.sun.management.jmxremote.autodiscovery=true -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=9091 -Dcom.sun.management.jmxremote.rmi.port=9091 -Djava.rmi.server.hostname=127.0.0.1 -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.local.only=false + -Dcryostat.discovery.jdp.enabled=true -Dcryostat.discovery.podman.enabled=true -XX:+FlightRecorder -XX:StartFlightRecording=filename=/tmp/,name=onstart,settings=default,disk=true,maxage=5m -Dcom.sun.management.jmxremote.autodiscovery=true -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=9091 -Dcom.sun.management.jmxremote.rmi.port=9091 -Djava.rmi.server.hostname=127.0.0.1 -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.local.only=false diff --git a/src/main/docker/Dockerfile.jvm b/src/main/docker/Dockerfile.jvm index 46aa123bd..497e4f1b3 100644 --- a/src/main/docker/Dockerfile.jvm +++ b/src/main/docker/Dockerfile.jvm @@ -77,7 +77,7 @@ # accessed directly. (example: "foo.example.com,bar.example.com") # ### -FROM registry.access.redhat.com/ubi8/openjdk-21-runtime:1.20-2.1724181173 +FROM registry.access.redhat.com/ubi9/openjdk-21-runtime:1.20-2.1725851019 ENV LANGUAGE='en_US:en' @@ -108,7 +108,7 @@ ENV SSL_TRUSTSTORE=$CONF_DIR/truststore.p12 \ USER root RUN mkdir -p $CONF_DIR \ && chmod -R g=u $CONF_DIR \ - && chown jboss:root $CONF_DIR + && chown default:root $CONF_DIR USER 185 RUN /deployments/app/truststore-setup.bash From 2ee31a67c4b7d5e3128829b83c140453cd513e44 Mon Sep 17 00:00:00 2001 From: Andrew Azores Date: Tue, 7 Jan 2025 14:21:33 -0500 Subject: [PATCH 4/5] fixup! Revert "revert to ubi8" --- compose/cryostat_docker.yml | 3 ++- compose/cryostat_k8s.yml | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/compose/cryostat_docker.yml b/compose/cryostat_docker.yml index 44a174dc1..b20a83f3b 100644 --- a/compose/cryostat_docker.yml +++ b/compose/cryostat_docker.yml @@ -34,7 +34,8 @@ services: CRYOSTAT_DISCOVERY_JDP_ENABLED: "true" JAVA_OPTS_APPEND: >- -XX:+FlightRecorder - -XX:StartFlightRecording=filename=/tmp,name=onstart,settings=default,disk=true,maxage=5m + -XX:StartFlightRecording=filename=/tmp/,name=onstart,settings=default,disk=true,maxage=5m + -XX:StartFlightRecording=filename=/tmp/,name=startup,settings=profile,disk=true,duration=30s -Dcom.sun.management.jmxremote.autodiscovery=true -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=9091 diff --git a/compose/cryostat_k8s.yml b/compose/cryostat_k8s.yml index 53b9d1ee1..b371b26da 100644 --- a/compose/cryostat_k8s.yml +++ b/compose/cryostat_k8s.yml @@ -19,7 +19,7 @@ services: environment: CRYOSTAT_DISCOVERY_PODMAN_ENABLED: "false" CRYOSTAT_DISCOVERY_JDP_ENABLED: "true" - JAVA_OPTS_APPEND: "-XX:+FlightRecorder -XX:StartFlightRecording=filename=/tmp,name=onstart,settings=default,disk=true,maxage=5m -Dcom.sun.management.jmxremote.autodiscovery=true -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=9091 -Dcom.sun.management.jmxremote.rmi.port=9091 -Djava.rmi.server.hostname=127.0.0.1 -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.local.only=false" + JAVA_OPTS_APPEND: "-XX:+FlightRecorder -XX:StartFlightRecording=filename=/tmp/,name=onstart,settings=default,disk=true,maxage=5m -Dcom.sun.management.jmxremote.autodiscovery=true -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=9091 -Dcom.sun.management.jmxremote.rmi.port=9091 -Djava.rmi.server.hostname=127.0.0.1 -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.local.only=false" restart: always healthcheck: test: curl --fail http://localhost:8181/health/liveness || exit 1 From 6a4cf38dfb362882feee1f86678ad4430c59d6fc Mon Sep 17 00:00:00 2001 From: Andrew Azores Date: Tue, 7 Jan 2025 14:22:14 -0500 Subject: [PATCH 5/5] fixup! chore(jdk): upgrade to JDK21 on UBI9 --- src/main/docker/Dockerfile.jvm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/docker/Dockerfile.jvm b/src/main/docker/Dockerfile.jvm index 497e4f1b3..84d622370 100644 --- a/src/main/docker/Dockerfile.jvm +++ b/src/main/docker/Dockerfile.jvm @@ -77,7 +77,7 @@ # accessed directly. (example: "foo.example.com,bar.example.com") # ### -FROM registry.access.redhat.com/ubi9/openjdk-21-runtime:1.20-2.1725851019 +FROM registry.access.redhat.com/ubi9/openjdk-21-runtime:1.21-1.1733995527 ENV LANGUAGE='en_US:en'