[keycloak-dev] [keycloak-user] Location of User Federation Provider jar in Keycloak 1.1 Beta-2

Marek Posolda mposolda at redhat.com
Fri Jan 16 12:19:02 EST 2015


Ok, I figured that I need to unzip WAR directly into auth-server 
directory to have structure like 
modules/system/layers/base/org/keycloak/keycloak-subsystem/main/auth-server/WEB-INF/... 
.

What I did before was converting WAR file to directory of the same name, 
so I had structure like: 
modules/system/layers/base/org/keycloak/keycloak-subsystem/main/auth-server/keycloak-server-1.1.0.Final-SNAPSHOT.war/WEB-INF/... 


Thanks!
Marek

On 16.1.2015 16:35, Stan Silvert wrote:
> I tested exploded mode yesterday with the latest release and it worked 
> fine for me.  Maybe you exploded it at the wrong directory level?
>
> On 1/16/2015 9:50 AM, Marek Posolda wrote:
>> On 16.1.2015 15:20, Stan Silvert wrote:
>>> On 1/16/2015 9:07 AM, Stian Thorgersen wrote:
>>>> Currently, I'm not overly happy with releasing 1.1.0.Final and it's 
>>>> down to this issue. I should have raised it before, but it 
>>>> completely slipped my mind :(
>>> We did talk about this at great length before.   I tried and tried to
>>> preserve the "drop it in the file system" approach.  It just plain 
>>> won't
>>> work for domains.
>>>> IMO we need:
>>>>
>>>> 1. A usable way to deploy a provider without using the CLI GUI
>>>> 2. Ideally be able to deploy a provider with an offline server
>>> We have 5 ways to add a provider:
>>> 1. CLI
>>> 2. CLI GUI
>>> 3. CLI script
>>> 4. Explode the WAR in the subsystem and drop it in WEB-INF/lib
>> I've just tried the exploded WAR approach, but had some issues. What 
>> I did with keycloak appliance was:
>> - Change the WAR file in 
>> modules/system/layers/base/org/keycloak/keycloak-subsystem/main/auth-server/keycloak-server-1.1.0.Final-SNAPSHOT.war 
>> to be exploded
>> - Change the configuration property "auth-server-exploded" to true in 
>> modules/system/layers/base/org/keycloak/keycloak-subsystem/main/module.xml
>>
>> With this auth-server didn't bootstrap for me at startup. Once I 
>> added provider to exploded WAR and pack it back to be file instead of 
>> directory, it started to work and my provider is found.
>>
>> So in shortcut, adding provider in offline mode works, but I needed 
>> to: unpack, copy provider JAR, pack it back.
>>
>> Did I something wrong to have exploded WAR working? Also can 
>> subsystem work with having exploded WAR by default? In this case it 
>> will be easy to add provider in offline mode as people can just copy 
>> them to unpacked location inside keycloak subsystem .
>>
>> Sorry if you already discuss this possibility, I may miss some 
>> details in previous discussion related to this;-)
>>
>> Marek
>>
>>> 5. Use the war dist and do it the old way.
>>>
>>> Why are these not sufficient?
>>>> ----- Original Message -----
>>>>> From: "Stan Silvert" <ssilvert at redhat.com>
>>>>> To: "Stian Thorgersen" <stian at redhat.com>
>>>>> Cc: keycloak-user at lists.jboss.org
>>>>> Sent: Friday, 16 January, 2015 2:13:24 PM
>>>>> Subject: Re: [keycloak-user] Location of User Federation Provider 
>>>>> jar in Keycloak 1.1 Beta-2
>>>>>
>>>>> On 1/16/2015 2:19 AM, Stian Thorgersen wrote:
>>>>>> ----- Original Message -----
>>>>>>> From: "Stan Silvert" <ssilvert at redhat.com>
>>>>>>> To: "Stian Thorgersen" <stian at redhat.com>
>>>>>>> Cc: keycloak-user at lists.jboss.org
>>>>>>> Sent: Thursday, 15 January, 2015 9:23:48 PM
>>>>>>> Subject: Re: [keycloak-user] Location of User Federation 
>>>>>>> Provider jar in
>>>>>>> Keycloak 1.1 Beta-2
>>>>>>>
>>>>>>> On 1/15/2015 9:29 AM, Stian Thorgersen wrote:
>>>>>>>> How is a provider added using the CLI? I can't find any 
>>>>>>>> examples on that.
>>>>>>> In the doc there is a step-by-step example of how to do it.  See 
>>>>>>> section
>>>>>>> 3.4.2.2.
>>>>>>> http://docs.jboss.org/keycloak/docs/1.1.0.Beta2/userguide/html/server-installation.html#d4e350 
>>>>>>>
>>>>>> That example uses the CLI GUI, we need one that uses plain CLI
>>>>> Plain CLI is harder in this case.  CLI GUI lets you browse for the 
>>>>> file
>>>>> you need.   Overall, plain CLI is a lot more error prone.
>>>>>
>>>>> If you do this once in CLI GUI then you will generate the CLI command
>>>>> that you can cut and paste into plain CLI or a script. But if you 
>>>>> want,
>>>>> I can include an example of that command.
>>>>>> There's also another issue with this approach, which I didn't 
>>>>>> stress enough
>>>>>> last time around, it requires the server to be running to add 
>>>>>> providers.
>>>>>> That makes it much harder to for example create a Docker 
>>>>>> cartridge that
>>>>>> includes some custom providers.
>>>>> Perhaps we just need to document the fact that you can still 
>>>>> explode the
>>>>> WAR and do it the old way?
>>>>>>>> Also, there are still several references in the docs and 
>>>>>>>> examples that
>>>>>>>> uses
>>>>>>>> the old approach of copying to WEB-INF/lib.
>>>>>>>>
>>>>>>>> ----- Original Message -----
>>>>>>>>> From: "Stan Silvert" <ssilvert at redhat.com>
>>>>>>>>> To: keycloak-user at lists.jboss.org
>>>>>>>>> Sent: Thursday, 15 January, 2015 2:09:56 PM
>>>>>>>>> Subject: Re: [keycloak-user] Location of User Federation 
>>>>>>>>> Provider jar in
>>>>>>>>> Keycloak 1.1 Beta-2
>>>>>>>>>
>>>>>>>>> Providers are now uploaded using WildFly CLI or CLI GUI.
>>>>>>>>>
>>>>>>>>> See
>>>>>>>>> http://docs.jboss.org/keycloak/docs/1.1.0.Beta2/userguide/html/server-installation.html#d4e350 
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> On 1/15/2015 6:46 AM, prab rrrr wrote:
>>>>>>>>>
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> Hi,
>>>>>>>>>
>>>>>>>>> I created a custom User Federation Provider and deployed it as 
>>>>>>>>> per the
>>>>>>>>> documentation. It worked in earlier versions (1.1 Beta-1) but 
>>>>>>>>> it appears
>>>>>>>>> that the location of Keycloak war in Wildfly has changed in 
>>>>>>>>> 1.1 Beta-2
>>>>>>>>> version and it is no longer inflated. Can someone suggest 
>>>>>>>>> where exactly
>>>>>>>>> I
>>>>>>>>> have to place the Federation provider jar in 1.1 Beta-2 version?
>>>>>>>>>
>>>>>>>>> Thanks,
>>>>>>>>> Raghu
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> _______________________________________________
>>>>>>>>> keycloak-user mailing list keycloak-user at lists.jboss.org
>>>>>>>>> https://lists.jboss.org/mailman/listinfo/keycloak-user
>>>>>>>>>
>>>>>>>>>
>>>>>>>>> _______________________________________________
>>>>>>>>> keycloak-user mailing list
>>>>>>>>> keycloak-user at lists.jboss.org
>>>>>>>>> https://lists.jboss.org/mailman/listinfo/keycloak-user
>>> _______________________________________________
>>> keycloak-dev mailing list
>>> keycloak-dev at lists.jboss.org
>>> https://lists.jboss.org/mailman/listinfo/keycloak-dev
>>
>



More information about the keycloak-dev mailing list