Ability to change metrics URL in docker container #3645
Replies: 4 comments
-
Thank you for reporting an issue! Pinging @jsenko to respond or triage. |
Beta Was this translation helpful? Give feedback.
-
I just tried extending the docker image to explicitly set |
Beta Was this translation helpful? Give feedback.
-
None of the approaches you tried is going to work for this property in particular. The issue is basically that the property you're trying to modify is a build time property and cannot be modified at runtime. To be able to change it you would need your own build of the application. If you take a look at the documentation you can see that there is a lock close to the property. |
Beta Was this translation helpful? Give feedback.
-
Got it. Thanks for the response. |
Beta Was this translation helpful? Give feedback.
-
Feature or Problem Description
My organization uses a different URL than the default
/metrics
specified in the Micrometer spec. I see that thequarkus-micrometer-registry-prometheus
extension supports thequarkus.micrometer.export.prometheus.path
property for changing the URL in its config reference, but I've tried settings this directly as an environment variable and a property in aJAVA_OPTIONS
environment variable for the docker container with no luck.Proposed Solution
I'm probably missing something obvious (maybe this exists already), but ideally, all quarkus properties are overrideable by environment variables in the docker container - as this is the most ubiquitous way to configure containers of any type.
Additional Context
It looks like another usage of
JAVA_OPTIONS
was discussed in this previous issue. However, I couldn't understand the resolution for the docker image without the k8s operator. I did try mounting a config volume including anapplication.properties
under/home/jboss
as described in the issue, but it wasn't picked up by the application. (I got/home/jboss
as the PWD from this dockerfile.)Digging through more issues I didn't see the aforementioned quarkus property listed in this output from the property configuration documentation issue, so I began to wonder if this was even configurable.
Beta Was this translation helpful? Give feedback.
All reactions