Running secured version of dcm4chee on docker

325 views
Skip to first unread message

Salifu Njidda

unread,
Apr 13, 2024, 4:37:24 AM4/13/24
to dcm4che
Hello all, I followed this doc: https://github.com/dcm4che/dcm4chee-arc-light/wiki/Run-secured-archive-services-on-a-single-host
all of the containers are running and i can login to keycloak but when i try to login to the archieve, i get an error: We are sorry...

Unexpected error when handling authentication request to identity provider.


I am unsure what to do as i have tried to create a user and client connection from keycloak yet no solution. Will appreciate any unblock.

Attarched are some of the screenshot.

Screenshot from 2024-04-13 09-10-04.png
Screenshot from 2024-04-13 09-10-23.png
Screenshot from 2024-04-13 09-10-04.png
Screenshot from 2024-04-13 09-11-46.png

Shefki Esadi

unread,
Apr 15, 2024, 1:16:32 PM4/15/24
to dcm4che
Hi,

you are using localhost overall, if you are using docker you can not use localhost as KeyCloak, archive ( and if you have separated the UI and archive also the UI ).
every docker container has is working as a separate ( virtual ) computer so that every one of them has his own ( local ) IP, so localhost for archive is something as localhost for KeyCloak etc.

Best Regard
Shefki Esadi
Message has been deleted

Shefki Esadi

unread,
Apr 17, 2024, 7:20:06 AM4/17/24
to dcm4che
Hi, 
the problem is, "localhost" for keycloak is a different IP, and "localhost" for the archive is different IP (  as the "localhost" is always its own IP which is the IP of the container respectively the computer when it's running ).
You can map a hostname with an IP in the docker-compose.yml and use that name instead here some example parts of docker-compose.yml and docker-compose.env:

```
 keycloak:
    image: dcm4che/keycloak:23.0.6
...
    env_file: docker-compose.env
    environment:
...
      KC_HOSTNAME: myhost                                            
... 
   depends_on:
...
  arc:
    image: dcm4che/dcm4chee-arc-psql:5.32.0-secure
...
    extra_hosts:
      - "myhost:192.168.0.29"
```
and in the docker-compose.env ( which is loaded anyway in every container by referencing it on docker-compose.yml )

```
...
ARCHIVE_HOST=myhost
AUTH_SERVER_URL=https://myhost:8843
...

```
Best Regard
Shefki Esadi
njidda...@gmail.com schrieb am Montag, 15. April 2024 um 19:51:48 UTC+2:
Hi Sheki, 
Thanks for the reply If I understand clearly, I have to use each docker container IP instead of local host.
Again I have keycloak running as a separate container so as the archive and other related containers.
They are all running in thesame network I created. 
Do I have to create a user in the dcm4che real on keycloak? When I try that it’s failing.

Njidda Salifu 


On 15 Apr 2024, at 18:16, Shefki Esadi <shral...@gmail.com> wrote:

Hi,
--
You received this message because you are subscribed to a topic in the Google Groups "dcm4che" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/dcm4che/MEQ9XGZOKoY/unsubscribe.
To unsubscribe from this group and all its topics, send an email to dcm4che+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/dcm4che/332ad97b-2719-45cb-bed9-724bedb3c664n%40googlegroups.com.

Salifu Njidda

unread,
Apr 17, 2024, 8:43:49 AM4/17/24
to dcm4che
I am still not able to fix this, you mentioned i am using localhost for both the keycloak and the archieve. I have the docker running on my local machine and evrything is running on the docker. When i visit any UR like https://localhost:8843/, 8080, 8443, 9993, etc all are redirecting to the login page which i can not still login to but when i http://localhost:8843/ i can login to the keycloak master/dcm4che using the credentials admin/changeit. from there nothing again. 

i tried this url https://localhost:8443/dcm4chee-arc/ui2 and was still redirected to the same login page in the attarched(initial attarch) yet i can not login. I am wondering where i am going wrong.

Salifu Njidda

unread,
Apr 17, 2024, 7:06:47 PM4/17/24
to dcm...@googlegroups.com
Thanks Shefki, 
I was using the docker command line instead of the compose. 
Now with this method when visit https://192.168.8.102:8843/admin/master/console/, i have an infinite loading of the archive ui.  
Again when i try to visit https://192.168.8.102:8443 i land on the wildfly welcome page and when i click amin console, i am redirected to https://192.168.8.102:9993/console/index.html which gives 401 error. I am still unsure if i am doing things correctly or there is something messed up on my machine. I am running ubuntu 22.04-LTS. Attached are my docker compose file and the env file as describe in your response.

docker-compose.yml
docker-compose.env
Reply all
Reply to author
Forward
Message has been deleted
0 new messages