-
Notifications
You must be signed in to change notification settings - Fork 6.4k
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
BaseUrl isn't getting used #16931
Comments
I'm getting the same error while using keycloak/keycloak-nodejs-connect, so your issue might be caused by something else |
In my case I was trying to write a test with |
Same error |
I think example in readme is wrong @stevehogdahl try below it works for me const KeycloakAdminClient = require('keycloak-admin').default;
const settings = {
username : config.KeycloakUsername,
password : config.KeycloakPassword,
grant_type: 'password',
client_id : 'admin-cli',
realmName : config.KeycloakRealm
}
const client = new KeycloakAdminClient( {
baseUrl: config.KeycloakBaseLocation,
});
await client.auth(settings); |
@patrykwegrzyn thank you, I'll give that a try. |
No. The REAME is correct, In your case maybe you were using the wrong "realm" and by not putting "realmName" in "KeycloakAdminClient" the library put you the realm "master" |
closing |
I'm getting the following error when calling the auth function:
ERROR Invoke Error { "errorType": "Error", "errorMessage": "connect ECONNREFUSED 127.0.0.1:8080", "trace": [ "Error: connect ECONNREFUSED 127.0.0.1:8080", " at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1107:14)" ] }
It looks like it's trying to hit the default baseUrl even though i passed in a new baseUrl. Code is below:
The text was updated successfully, but these errors were encountered: