Fix customer-portal-cli example

This commit is contained in:
Stian Thorgersen 2014-05-29 14:04:10 +01:00
parent 8908fbef58
commit 1ede6e70b7
4 changed files with 9 additions and 3 deletions

View file

@ -20,6 +20,10 @@
<artifactId>keycloak-installed-adapter</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>org.jboss.logging</groupId>
<artifactId>jboss-logging</artifactId>
</dependency>
</dependencies>
<build>

View file

@ -1,7 +1,7 @@
{
"realm" : "demo",
"realm-public-key" : "MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQCrVrCuTtArbgaZzL1hvh0xtL5mc7o0NqPVnYXkLvgcwiC3BjLGw1tGEGoJaXDuSaRllobm53JBhjx33UNv+5z/UMG4kytBWxheNVKnL6GgqlNabMaFfPLPCF8kAgKnsi79NMo+n6KnSY8YeUmec/p2vjO2NjsSAVcWEQMVhJ31LwIDAQAB",
"auth-server-url" : "http://localhost:8081/auth",
"auth-server-url" : "http://localhost:8080/auth",
"ssl-not-required" : true,
"resource" : "customer-portal-cli",
"public-client" : true

View file

@ -73,6 +73,10 @@
"client": "customer-portal-js",
"roles": ["user"]
},
{
"client": "customer-portal-cli",
"roles": ["user"]
},
{
"client": "angular-product",
"roles": ["user"]

View file

@ -100,7 +100,6 @@ public class KeycloakInstalled {
.queryParam(OAuth2Constants.CLIENT_ID, deployment.getResourceName())
.queryParam(OAuth2Constants.REDIRECT_URI, redirectUri)
.queryParam(OAuth2Constants.STATE, state)
.queryParam("login", "true")
.build().toString();
Desktop.getDesktop().browse(new URI(authUrl));
@ -156,7 +155,6 @@ public class KeycloakInstalled {
String authUrl = deployment.getAuthUrl().clone()
.queryParam(OAuth2Constants.CLIENT_ID, deployment.getResourceName())
.queryParam(OAuth2Constants.REDIRECT_URI, redirectUri)
.queryParam("login", "true")
.build().toString();
printer.println("Open the following URL in a browser. After login copy/paste the code back and press <enter>");