-
Notifications
You must be signed in to change notification settings - Fork 2.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cannot override OAuth URL at run time #5800
Comments
@berkyvz is the issue only occurs on JVM mode or is it a native only issue ? |
It is a native only issue. It works in JVM mode and dev mode |
@loicmathieu Hi Loic, looks like it is still needed to make the configuration runtime init. |
@sberyozkin Hi, as I understood there are two options for oauth2 client (elytron & oidc). Which one is recommended. If oidc is recommended and it does not have this issue, we can go with it. |
@muratkarakas if you use a JWT OIDC token then |
@sberyozkin thanks for your response, we are using simple token with custom auth2server(springboot based). I have tested quarkus-oidc with it but it did not work because of compatibility issues(realm url etc..). Currently we are using quarkus profile feature as a work around solution quarkus.oauth2.introspection-url= http://localhost:8081/auth/oauth/introspect |
Fixed via #5937 |
Describe the bug
We decide to use Quarkus in cloud native application as a company but it seems there is a bug. I can not change the properties of
quarkus.oauth2
Expected behavior
The oauth properties should be change in runtime without using profile.
Actual behavior
Github Link : https://github.com/berkyvz/quarkus-issues/tree/master/quarkus-oauth2
I have a project with quarkus 1.0.0.Final with gradle. There is .properties file that keeping OAuth properties. The properties shown below;
I am trying to override these properties with using
-D
flags at run time. Actually, It seems like it is changing the properties. However, the truth is it can't change thequarkus.oauth2.introspection-url
property. I am building project with command./gradlew clean buildNative --docker-build=true
and run withWhen I call the controller that simply returns the configuration properties as
HashMap<String,String>
, the reponse is shown below asJSON
;The controller;
hello/props
But when I send the request to
http://localhost:8080/hello/secure
it is not using the new prop, it stil uses the localhost instead ofhttp://abc:8081/auth/oauth/introspect-native
The secure controller hello/secure;
The logs
Why
/props
controller send the props as"quarkus.oauth2.introspection-url": "http://abc:8081/auth/oauth/introspect-native"
but OAuth still send the request to thehttp://localhost:8081/auth/oauth/introspect
. In addition to this, It works in.jar
build package.To Reproduce
Steps to reproduce the behavior:
Configuration
Screenshots
(If applicable, add screenshots to help explain your problem.)
Environment (please complete the following information):
uname -a
orver
: Linux berk-yavuz 4.15.0-70-generic OpenTracing -- DOES NOT WORK #79-Ubuntu SMP Tue Nov 12 10:36:11 UTC 2019 x86_64 x86_64 x86_64 GNU/Linuxjava -version
: openjdk version "1.8.0_232"The text was updated successfully, but these errors were encountered: