From 448a15b2ca84ae61b4dde956ba61979a81491ee5 Mon Sep 17 00:00:00 2001 From: vramik Date: Thu, 7 Jan 2016 18:58:32 +0100 Subject: [PATCH] install adapter via cli script from java code after start --- .../servers/wildfly/pom.xml | 2 - .../tests/adapters/as7/pom.xml | 69 +++++---- .../adapters/as7/src/main/xslt/arquillian.xsl | 2 + .../adapters/as7/src/main/xslt/standalone.xsl | 51 ------- .../tests/adapters/eap6/pom.xml | 83 +---------- .../eap6/src/main/xslt/standalone.xsl | 51 ------- .../tests/adapters/pom.xml | 8 +- .../tests/adapters/wildfly/pom.xml | 30 ---- .../tests/adapters/wildfly8/pom.xml | 30 ---- .../wildfly8/src/main/xslt/standalone.xsl | 51 ------- .../integration-arquillian/tests/base/pom.xml | 3 + .../arquillian/ContainersTestEnricher.java | 102 +++++++++---- .../adapter/AbstractAdapterTest.java | 18 +-- .../resources/adapter-test/demorealm.json | 135 ++++++++++++------ 14 files changed, 233 insertions(+), 402 deletions(-) delete mode 100644 testsuite/integration-arquillian/tests/adapters/as7/src/main/xslt/standalone.xsl delete mode 100644 testsuite/integration-arquillian/tests/adapters/eap6/src/main/xslt/standalone.xsl delete mode 100644 testsuite/integration-arquillian/tests/adapters/wildfly8/src/main/xslt/standalone.xsl diff --git a/testsuite/integration-arquillian/servers/wildfly/pom.xml b/testsuite/integration-arquillian/servers/wildfly/pom.xml index f30d6c26da..361073713e 100644 --- a/testsuite/integration-arquillian/servers/wildfly/pom.xml +++ b/testsuite/integration-arquillian/servers/wildfly/pom.xml @@ -273,7 +273,6 @@ maven-resources-plugin - 2.7 copy-keystore @@ -309,7 +308,6 @@ org.apache.maven.plugins maven-enforcer-plugin - 1.4 enforce-properties diff --git a/testsuite/integration-arquillian/tests/adapters/as7/pom.xml b/testsuite/integration-arquillian/tests/adapters/as7/pom.xml index f670ea3c0a..135c1bf180 100644 --- a/testsuite/integration-arquillian/tests/adapters/as7/pom.xml +++ b/testsuite/integration-arquillian/tests/adapters/as7/pom.xml @@ -15,22 +15,29 @@ 7.1.1.Final ${containers.home}/jboss-as-${as7.version} ${containers.home}/keycloak-as7-adapter-dist + 150 + + org.wildfly + wildfly-arquillian-container-managed + + + + org.jboss.as + jboss-as-arquillian-container-managed + ${as7.version} + org.jboss.as jboss-as-dist ${as7.version} zip - - org.wildfly - wildfly-arquillian-container-managed - org.keycloak - keycloak-eap6-adapter-dist + keycloak-as7-adapter-dist zip @@ -79,15 +86,36 @@ org.apache.maven.plugins maven-surefire-plugin - 2.18.1 true ${app.server.as7.home} ${adapter.libs.as7} + ${startup.timeout.sec} + ${adapter.as7.jdk7.path} + + + org.apache.maven.plugins + maven-enforcer-plugin + + + enforce-properties + + enforce + + + + + adapter.as7.jdk7.path + + + + + + @@ -102,35 +130,6 @@ ${app.server.as7.home} - - - - org.codehaus.mojo - xml-maven-plugin - - - configure-adapter-subsystem - process-resources - - transform - - - - - ${app.server.as7.home}/standalone/configuration - - standalone.xml - - src/main/xslt/standalone.xsl - ${app.server.as7.home}/standalone/configuration - - - - - - - - diff --git a/testsuite/integration-arquillian/tests/adapters/as7/src/main/xslt/arquillian.xsl b/testsuite/integration-arquillian/tests/adapters/as7/src/main/xslt/arquillian.xsl index 9ba1e9403f..1ffc5c347f 100644 --- a/testsuite/integration-arquillian/tests/adapters/as7/src/main/xslt/arquillian.xsl +++ b/testsuite/integration-arquillian/tests/adapters/as7/src/main/xslt/arquillian.xsl @@ -20,6 +20,8 @@ localhost remote ${app.server.management.port.jmx} + ${startup.timeout.sec} + ${adapter.as7.jdk7.path} diff --git a/testsuite/integration-arquillian/tests/adapters/as7/src/main/xslt/standalone.xsl b/testsuite/integration-arquillian/tests/adapters/as7/src/main/xslt/standalone.xsl deleted file mode 100644 index 5aac0f02d6..0000000000 --- a/testsuite/integration-arquillian/tests/adapters/as7/src/main/xslt/standalone.xsl +++ /dev/null @@ -1,51 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/testsuite/integration-arquillian/tests/adapters/eap6/pom.xml b/testsuite/integration-arquillian/tests/adapters/eap6/pom.xml index 11abbf17ff..44fce9a8a9 100644 --- a/testsuite/integration-arquillian/tests/adapters/eap6/pom.xml +++ b/testsuite/integration-arquillian/tests/adapters/eap6/pom.xml @@ -12,17 +12,17 @@ Adapter Tests on EAP 6 - ${containers.home} + ${containers.home}/jboss-eap-6.4 ${containers.home}/keycloak-eap6-adapter-dist - false - + org.wildfly wildfly-arquillian-container-managed - --> - + + org.jboss.as jboss-as-arquillian-container-managed @@ -53,11 +53,10 @@ org.apache.maven.plugins maven-surefire-plugin - 2.18.1 true - ${app.server.eap6.home}/jboss-eap-6.4 + ${app.server.eap6.home} ${adapter.libs.eap6} @@ -97,46 +96,6 @@ - - prod - - - prod - true - - - - true - - - - - org.apache.maven.plugins - maven-dependency-plugin - - - unpack-eap6-with-adapter - generate-resources - - unpack - - - - - org.keycloak - rh-sso-eap6-adapter - ${version.rh.soo} - zip - ${app.server.eap6.home} - - - - - - - - - adapter-jdk @@ -190,36 +149,6 @@ ${app.server.eap6.home} - - - - org.codehaus.mojo - xml-maven-plugin - - - configure-adapter-subsystem - process-resources - - transform - - - ${skip.configure.adapter.subsystem} - - - ${app.server.eap6.home}/standalone/configuration - - standalone.xml - - src/main/xslt/standalone.xsl - ${app.server.eap6.home}/standalone/configuration - - - - - - - - ssl diff --git a/testsuite/integration-arquillian/tests/adapters/eap6/src/main/xslt/standalone.xsl b/testsuite/integration-arquillian/tests/adapters/eap6/src/main/xslt/standalone.xsl deleted file mode 100644 index fb3612beff..0000000000 --- a/testsuite/integration-arquillian/tests/adapters/eap6/src/main/xslt/standalone.xsl +++ /dev/null @@ -1,51 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/testsuite/integration-arquillian/tests/adapters/pom.xml b/testsuite/integration-arquillian/tests/adapters/pom.xml index 5474ad9263..5e215fb809 100644 --- a/testsuite/integration-arquillian/tests/adapters/pom.xml +++ b/testsuite/integration-arquillian/tests/adapters/pom.xml @@ -189,7 +189,6 @@ org.apache.maven.plugins maven-dependency-plugin - 2.10 example-wars @@ -384,6 +383,13 @@ **/adapter/**/*Test.java + + no-relative + + + **/adapter/**/WildflyRelative*Test.java + + diff --git a/testsuite/integration-arquillian/tests/adapters/wildfly/pom.xml b/testsuite/integration-arquillian/tests/adapters/wildfly/pom.xml index fbac8fe3c8..46224891cb 100644 --- a/testsuite/integration-arquillian/tests/adapters/wildfly/pom.xml +++ b/testsuite/integration-arquillian/tests/adapters/wildfly/pom.xml @@ -100,35 +100,6 @@ ${app.server.wildfly.home} - - - - org.codehaus.mojo - xml-maven-plugin - - - configure-adapter-subsystem - process-resources - - transform - - - - - ${app.server.wildfly.home}/standalone/configuration - - standalone.xml - - src/main/xslt/standalone.xsl - ${app.server.wildfly.home}/standalone/configuration - - - - - - - - ssl @@ -166,7 +137,6 @@ maven-resources-plugin - 2.7 copy-keystore diff --git a/testsuite/integration-arquillian/tests/adapters/wildfly8/pom.xml b/testsuite/integration-arquillian/tests/adapters/wildfly8/pom.xml index f6378e8242..2148e18015 100644 --- a/testsuite/integration-arquillian/tests/adapters/wildfly8/pom.xml +++ b/testsuite/integration-arquillian/tests/adapters/wildfly8/pom.xml @@ -79,7 +79,6 @@ org.apache.maven.plugins maven-surefire-plugin - 2.18.1 true @@ -102,35 +101,6 @@ ${app.server.wildfly.home} - - - - org.codehaus.mojo - xml-maven-plugin - - - configure-adapter-subsystem - process-resources - - transform - - - - - ${app.server.wildfly.home}/standalone/configuration - - standalone.xml - - src/main/xslt/standalone.xsl - ${app.server.wildfly.home}/standalone/configuration - - - - - - - - diff --git a/testsuite/integration-arquillian/tests/adapters/wildfly8/src/main/xslt/standalone.xsl b/testsuite/integration-arquillian/tests/adapters/wildfly8/src/main/xslt/standalone.xsl deleted file mode 100644 index 364d8037c4..0000000000 --- a/testsuite/integration-arquillian/tests/adapters/wildfly8/src/main/xslt/standalone.xsl +++ /dev/null @@ -1,51 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/testsuite/integration-arquillian/tests/base/pom.xml b/testsuite/integration-arquillian/tests/base/pom.xml index 9c658fe778..c1e5e9c189 100644 --- a/testsuite/integration-arquillian/tests/base/pom.xml +++ b/testsuite/integration-arquillian/tests/base/pom.xml @@ -15,6 +15,7 @@ - - - + - @@ -50,6 +51,7 @@ ${exclude.console} ${exclude.account} ${exclude.client} + ${exclude.migration} @@ -77,6 +79,7 @@ **/console/**/*Test.java **/account/**/*Test.java **/client/**/*Test.java + **/migration/**/*Test.java diff --git a/testsuite/integration-arquillian/tests/base/src/main/java/org/keycloak/testsuite/arquillian/ContainersTestEnricher.java b/testsuite/integration-arquillian/tests/base/src/main/java/org/keycloak/testsuite/arquillian/ContainersTestEnricher.java index 50beaa69e0..4a7473d333 100644 --- a/testsuite/integration-arquillian/tests/base/src/main/java/org/keycloak/testsuite/arquillian/ContainersTestEnricher.java +++ b/testsuite/integration-arquillian/tests/base/src/main/java/org/keycloak/testsuite/arquillian/ContainersTestEnricher.java @@ -1,10 +1,14 @@ package org.keycloak.testsuite.arquillian; +import java.io.BufferedReader; import java.io.File; import java.io.IOException; +import java.io.InputStream; +import java.io.InputStreamReader; import java.net.MalformedURLException; import java.net.URL; import java.util.LinkedList; +import java.util.concurrent.TimeUnit; import org.apache.commons.io.FileUtils; import org.jboss.arquillian.container.spi.Container; import org.jboss.arquillian.container.spi.ContainerRegistry; @@ -19,6 +23,7 @@ import org.jboss.arquillian.core.api.annotation.Observes; import org.jboss.arquillian.test.spi.annotation.ClassScoped; import org.jboss.arquillian.test.spi.annotation.SuiteScoped; import org.jboss.arquillian.container.spi.event.container.AfterStart; +import org.jboss.arquillian.container.spi.event.container.BeforeStart; import org.jboss.arquillian.test.spi.event.suite.BeforeClass; import org.jboss.arquillian.test.spi.event.suite.BeforeSuite; import org.jboss.logging.Logger; @@ -83,7 +88,7 @@ public class ContainersTestEnricher { } init = true; } - + /* * non-javadoc * @@ -103,43 +108,92 @@ public class ContainersTestEnricher { * After start container. Server logs are checked (in case jboss based container). * In case of migration scenario: previous container is stopped. */ - public void afterStart(@Observes AfterStart event) throws IOException { - if (System.getProperty("check.server.log", "true").equals("true")) { - checkServerLog(); + public void afterStart(@Observes AfterStart event) throws IOException, InterruptedException { + Container container = containers.pollFirst(); + String jbossHomePath = null; + + if (isJBossBased(container)) { + jbossHomePath = container.getContainerConfiguration().getContainerProperties().get("jbossHome"); + log.debug("jbossHome: " + jbossHomePath + "\n"); + + if (System.getProperty("check.server.log", "true").equals("true")) { + checkServerLog(jbossHomePath); + } } if (migrationTests && !alreadyStopped) { log.info("\n\n### Stopping keycloak " + System.getProperty("version", "- previous") + " ###\n"); stopSuiteContainers.fire(new StopSuiteContainers()); log.info("\n\n### Starting keycloak current version ###\n"); + alreadyStopped = true; } - alreadyStopped = true; + + if (isJBossBased(container) && container.getName().startsWith("app-server")) { + log.info("Installing adapter to app server via cli script"); + String jbossCliPath = jbossHomePath + "/bin/jboss-cli.sh"; + String scriptPathArg = "--file=" + jbossHomePath + "/bin/adapter-install.cli"; + String managementPort = container.getContainerConfiguration().getContainerProperties().get("managementPort"); + String controllerArg = "--controller=localhost:" + managementPort; + + execCommand(new String[]{"/bin/sh", jbossCliPath, "--connect", scriptPathArg, controllerArg}); + log.debug("Restarting container"); + execCommand(new String[]{"/bin/sh", jbossCliPath, "--connect", "--command=:reload", controllerArg}); + } + } + + private void execCommand(String... command) throws IOException, InterruptedException { + Process process = Runtime.getRuntime().exec(command); + + printOutput(process.getInputStream()); + + if (process.waitFor(10, TimeUnit.SECONDS)) { + if (process.exitValue() != 0) { + log.error("Std Error:"); + printOutput(process.getErrorStream()); + throw new RuntimeException("Adapter installation failed."); + } + } else { + process.destroy(); + throw new RuntimeException("Timeout after 10 seconds."); + } + } + + private void printOutput(InputStream is) throws IOException { + BufferedReader reader = new BufferedReader(new InputStreamReader(is)); + StringBuilder builder = new StringBuilder(); + while (reader.ready()) { + builder.append(reader.readLine()); + } + log.info(builder); + } + + private boolean isJBossBased(Container container) { + if (container == null) { + return false; + } + return container.getName().matches("a.*-server-wildfly") + || container.getName().matches("a.*-server-eap.") + || container.getName().equals("app-server-as7"); } /* * non-javadoc * - * check server logs (in case jboss based container) whether there are no ERRORs or SEVEREs + * check server logs whether there are no ERRORs or SEVEREs */ - private void checkServerLog() throws IOException { - Container container = containers.removeFirst(); - if (container.getName().equals("auth-server-wildfly") - || container.getName().matches("auth-server-eap.")) { - String jbossHomePath = container.getContainerConfiguration().getContainerProperties().get("jbossHome"); - log.debug("jbossHome: " + jbossHomePath + "\n"); + private void checkServerLog(String jbossHomePath) throws IOException { + File serverLog = new File(jbossHomePath + "/standalone/log/server.log"); + String serverLogContent = FileUtils.readFileToString(serverLog); - String serverLogContent = FileUtils.readFileToString(new File(jbossHomePath + "/standalone/log/server.log")); + boolean containsError + = serverLogContent.contains("ERROR") + || serverLogContent.contains("SEVERE") + || serverLogContent.contains("Exception "); + //There is expected string "Exception" in server log: Adding provider + //singleton org.keycloak.services.resources.ModelExceptionMapper - boolean containsError - = serverLogContent.contains("ERROR") - || serverLogContent.contains("SEVERE") - || serverLogContent.contains("Exception "); - //There is expected string "Exception" in server log: Adding provider - //singleton org.keycloak.services.resources.ModelExceptionMapper - - if (containsError) { - throw new RuntimeException(container.getName() + ": Server log contains ERROR."); - } + if (containsError) { + throw new RuntimeException(serverLog.getPath() + " contains ERROR."); } } @@ -154,9 +208,7 @@ public class ContainersTestEnricher { appServerQualifier = getAppServerQualifier(testClass); if (!controller.isStarted(appServerQualifier)) { - log.info("\nSTARTING APP SERVER: " + appServerQualifier + "\n"); controller.start(appServerQualifier); - log.info(""); } initializeTestContext(testClass); diff --git a/testsuite/integration-arquillian/tests/base/src/test/java/org/keycloak/testsuite/adapter/AbstractAdapterTest.java b/testsuite/integration-arquillian/tests/base/src/test/java/org/keycloak/testsuite/adapter/AbstractAdapterTest.java index 056a489b19..5a6c6065d7 100644 --- a/testsuite/integration-arquillian/tests/base/src/test/java/org/keycloak/testsuite/adapter/AbstractAdapterTest.java +++ b/testsuite/integration-arquillian/tests/base/src/test/java/org/keycloak/testsuite/adapter/AbstractAdapterTest.java @@ -79,14 +79,16 @@ public abstract class AbstractAdapterTest extends AbstractAuthTest { } protected void modifyClientUrls(RealmRepresentation realm, String regex, String replacement) { - for (ClientRepresentation client : realm.getClients()) { - String baseUrl = client.getBaseUrl(); - if (baseUrl != null) { - client.setBaseUrl(baseUrl.replaceAll(regex, replacement)); - } - String adminUrl = client.getAdminUrl(); - if (adminUrl != null) { - client.setAdminUrl(adminUrl.replaceAll(regex, replacement)); + if (realm.getClients() != null) { + for (ClientRepresentation client : realm.getClients()) { + String baseUrl = client.getBaseUrl(); + if (baseUrl != null) { + client.setBaseUrl(baseUrl.replaceAll(regex, replacement)); + } + String adminUrl = client.getAdminUrl(); + if (adminUrl != null) { + client.setAdminUrl(adminUrl.replaceAll(regex, replacement)); + } } } } diff --git a/testsuite/integration-arquillian/tests/base/src/test/resources/adapter-test/demorealm.json b/testsuite/integration-arquillian/tests/base/src/test/resources/adapter-test/demorealm.json index 5b82ec6387..70dc85aae4 100644 --- a/testsuite/integration-arquillian/tests/base/src/test/resources/adapter-test/demorealm.json +++ b/testsuite/integration-arquillian/tests/base/src/test/resources/adapter-test/demorealm.json @@ -21,7 +21,7 @@ { "type" : "password", "value" : "password" } ], - "realmRoles": [ "user", "admin" ], + "realmRoles": [ "user" ], "applicationRoles": { "account": [ "manage-account" ] } @@ -34,12 +34,36 @@ "lastName": "Posolda", "credentials" : [ { "type" : "password", - "value" : "password" } + "value" : "password" } ], "realmRoles": [ "user" ], "applicationRoles": { "account": [ "manage-account" ] } + }, + { + "username" : "topGroupUser", + "enabled": true, + "email" : "top@redhat.com", + "credentials" : [ + { "type" : "password", + "value" : "password" } + ], + "groups": [ + "/top" + ] + }, + { + "username" : "level2GroupUser", + "enabled": true, + "email" : "level2@redhat.com", + "credentials" : [ + { "type" : "password", + "value" : "password" } + ], + "groups": [ + "/top/level2" + ] } ], "roles" : { @@ -54,6 +78,29 @@ } ] }, + "groups" : [ + { + "name": "top", + "attributes": { + "topAttribute": ["true"] + + }, + "realmRoles": ["user"], + "clientRoles": { + "account": ["manage-account"] + }, + "subGroups": [ + { + "name": "level2", + "realmRoles": ["admin"], + "attributes": { + "level2Attribute": ["true"] + + } + } + ] + } + ], "scopeMappings": [ { "client": "third-party", @@ -69,38 +116,39 @@ } ], - "clients": [ + "applications": [ { - "clientId": "customer-portal", + "name": "customer-portal", "enabled": true, - "adminUrl": "/customer-portal", - "baseUrl": "/customer-portal", + "directAccessGrantsEnabled": true, + "adminUrl": "http://localhost:8081/customer-portal", + "baseUrl": "http://localhost:8081/customer-portal", "redirectUris": [ - "/customer-portal/*" + "http://localhost:8081/customer-portal/*" ], "secret": "password" }, { - "clientId": "customer-cookie-portal", + "name": "customer-cookie-portal", "enabled": true, - "baseUrl": "/customer-cookie-portal", + "baseUrl": "http://localhost:8081/customer-cookie-portal", "redirectUris": [ - "/customer-cookie-portal/*" + "http://localhost:8081/customer-cookie-portal/*" ], "secret": "password" }, { - "clientId": "customer-portal-js", + "name": "customer-portal-js", "enabled": true, "publicClient": true, - "adminUrl": "/customer-portal-js", - "baseUrl": "/customer-portal-js", + "adminUrl": "http://localhost:8081/customer-portal-js", + "baseUrl": "http://localhost:8081/customer-portal-js", "redirectUris": [ - "/customer-portal-js/*" + "http://localhost:8080/customer-portal-js/*" ] }, { - "clientId": "customer-portal-cli", + "name": "customer-portal-cli", "enabled": true, "publicClient": true, "redirectUris": [ @@ -109,51 +157,56 @@ ] }, { - "clientId": "product-portal", + "name": "product-portal", "enabled": true, - "adminUrl": "/product-portal", - "baseUrl": "/product-portal", + "adminUrl": "http://localhost:8081/product-portal", + "baseUrl": "http://localhost:8081/product-portal", "redirectUris": [ - "/product-portal/*" + "http://localhost:8081/product-portal/*" ], "secret": "password" }, { - "clientId": "secure-portal", + "name": "secure-portal", "enabled": true, - "adminUrl": "/secure-portal", - "baseUrl": "/secure-portal", + "adminUrl": "http://localhost:8081/secure-portal", + "baseUrl": "http://localhost:8081/secure-portal", + "clientAuthenticatorType": "client-jwt", "redirectUris": [ - "/secure-portal/*" + "http://localhost:8081/secure-portal/*" + ], + "attributes": { + "jwt.credential.certificate": "MIICnTCCAYUCBgFPPLDaTzANBgkqhkiG9w0BAQsFADASMRAwDgYDVQQDDAdjbGllbnQxMB4XDTE1MDgxNzE3MjI0N1oXDTI1MDgxNzE3MjQyN1owEjEQMA4GA1UEAwwHY2xpZW50MTCCASIwDQYJKoZIhvcNAQEBBQADggEPADCCAQoCggEBAIUjjgv+V3s96O+Za9002Lp/trtGuHBeaeVL9dFKMKzO2MPqdRmHB4PqNlDdd28Rwf5Xn6iWdFpyUKOnI/yXDLhdcuFpR0sMNK/C9Lt+hSpPFLuzDqgtPgDotlMxiHIWDOZ7g9/gPYNXbNvjv8nSiyqoguoCQiiafW90bPHsiVLdP7ZIUwCcfi1qQm7FhxRJ1NiW5dvUkuCnnWEf0XR+Wzc5eC9EgB0taLFiPsSEIlWMm5xlahYyXkPdNOqZjiRnrTWm5Y4uk8ZcsD/KbPTf/7t7cQXipVaswgjdYi1kK2/zRwOhg1QwWFX/qmvdd+fLxV0R6VqRDhn7Qep2cxwMxLsCAwEAATANBgkqhkiG9w0BAQsFAAOCAQEAKE6OA46sf20bz8LZPoiNsqRwBUDkaMGXfnob7s/hJZIIwDEx0IAQ3uKsG7q9wb+aA6s+v7S340zb2k3IxuhFaHaZpAd4CyR5cn1FHylbzoZ7rI/3ASqHDqpljdJaFqPH+m7nZWtyDvtZf+gkZ8OjsndwsSBK1d/jMZPp29qYbl1+XfO7RCp/jDqro/R3saYFaIFiEZPeKn1hUJn6BO48vxH1xspSu9FmlvDOEAOz4AuM58z4zRMP49GcFdCWr1wkonJUHaSptJaQwmBwLFUkCbE5I1ixGMb7mjEud6Y5jhfzJiZMo2U8RfcjNbrN0diZl3jB6LQIwESnhYSghaTjNQ==" + } + }, + { + "name": "session-portal", + "enabled": true, + "adminUrl": "http://localhost:8081/session-portal", + "baseUrl": "http://localhost:8081/session-portal", + "redirectUris": [ + "http://localhost:8081/session-portal/*" ], "secret": "password" }, { - "clientId": "session-portal", + "name": "input-portal", "enabled": true, - "adminUrl": "/session-portal", - "baseUrl": "/session-portal", + "adminUrl": "http://localhost:8081/input-portal", + "baseUrl": "http://localhost:8081/input-portal", "redirectUris": [ - "/session-portal/*" + "http://localhost:8081/input-portal/*" ], "secret": "password" - }, + } + ], + "oauthClients": [ { - "clientId": "input-portal", - "enabled": true, - "adminUrl": "/input-portal", - "baseUrl": "/input-portal", - "redirectUris": [ - "/input-portal/*" - ], - "secret": "password" - }, - { - "clientId": "third-party", + "name": "third-party", "enabled": true, "redirectUris": [ - "/oauth-client/*", - "/oauth-client-cdi/*" + "http://localhost:8081/oauth-client/*", + "http://localhost:8081/oauth-client-cdi/*" ], "secret": "password" }