Hello everyone, i need some help here;
I was trying to deploy Orthanc with Docker and SSL using the OrthancCon 2023 PDF that have some instructions (The repo have files missing?). Well, when i’m finished of configurate everything the auth-service doesn’t work properly, so i had to investigate from the repo of it; later, from reading and reading. I successfully deploy everything, but, when i log into Orthanc Explorer, i doesn’t show all the menues that shows in the PDF, in the Chrome console shows
"Failed to load resource: the server responded with a status of 400 (Bad Request)"
Next by the “explanation” of the error:
1. $e
1. code: "ERR_BAD_REQUEST"
2. config: {transitional: {…}, adapter: Array(2), transformRequest: Array(1), transformResponse: Array(1), timeout: 0, …}
3. message: "Request failed with status code 400"
4. name: "AxiosError"
5. request: XMLHttpRequest {onreadystatechange: null, readyState: 4, timeout: 0, withCredentials: false, upload: XMLHttpRequestUpload, …}
6. response: {data: {…}, status: 400, statusText: 'Bad Request', headers: Zo, config: {…}, …}
7. stack: "AxiosError: Request failed with status code 400\n at R1
And the frontpage looks like this:
From here, i don’t know what to do. I’m giving the docker-compose.yml content in another comment.
Thank you very much for your time.
Here’s the content of the docker-compose.yml:
services:
nginx:
image: orthancteam/orthanc-nginx:24.5.1
depends_on: [orthanc, orthanc-auth-service]
restart: unless-stopped
ports: ["8080:80"]
environment:
ENABLE_ORTHANC: "true"
ENABLE_KEYCLOAK: "true"
ENABLE_ORTHANC_TOKEN_SERVICE: "true"
orthanc:
image: orthancteam/orthanc:24.5.1
volumes:
- ./orthanc-admin.jsonc:/etc/orthanc/orthanc-admin.json
- ./orthanc-common.jsonc:/etc/orthanc/orthanc-common.json
- orthanc-data:/var/lib/orthanc/db:Z
restart: unless-stopped
environment:
ORTHANC__NAME: "Orthanc"
VERBOSE_ENABLED: "true"
VERBOSE_STARTUP: "true"
ORTHANC__ORTHANC_EXPLORER_2__UI_OPTIONS__STUDY_LIST_SEARCH_MODE: "search-button"
ORTHANC__ORTHANC_EXPLORER_2__UI_OPTIONS__STUDY_LIST_CONTENT_IF_NO_SEARCH: "empty"
ORTHANC__ORTHANC_EXPLORER_2__IS_DEFAULT_ORTHANC_UI: "true"
ORTHANC__ORTHANC_EXPLORER_2__UI_OPTIONS__SHOW_SAME_PATIENT_STUDIES_FILTER: |
["PatientBirthDate", "PatientID"]
STONE_WEB_VIEWER_PLUGIN_ENABLED: "true"
ORTHANC__STONE_WEB_VIEWER__SHOW_INFO_PANEL_AT_STARTUP: "Never"
ORTHANC__DICOM_WEB__PUBLIC_ROOT: "/orthanc/dicom-web/"
ORTHANC__DATABASE_SERVER_IDENTIFIER: "orthanc1"
ORTHANC__POSTGRESQL__ENABLE_INDEX: "true"
ORTHANC__POSTGRESQL__HOST: "postgres"
ORTHANC__POSTGRESQL__INDEX_CONNECTIONS_COUNT: 50
ORTHANC__POSTGRESQL__TRANSACTION_MODE: "ReadCommitted"
ORTHANC__POSTGRESQL__ENABLE_STORAGE: "false"
ORTHANC__AUTHORIZATION__WEB_SERVICE_USER_NAME: "admin"
ORTHANC__AUTHORIZATION__WEB_SERVICE_PASSWORD: "pwd"
# secrets:
#- postgres-azure.secret.json
#- ORTHANC__AUTHORIZATION__WEB_SERVICE_PASSWORD
postgres:
image: postgres:15
restart: unless-stopped
volumes: ["orthanc-index:/var/lib/postgresql/data:Z"]
environment:
POSTGRES_HOST_AUTH_METHOD: "trust"
orthanc-auth-service:
image: orthancteam/orthanc-auth-service:24.5.1
depends_on: [keycloak]
volumes:
- ./permissions.json:/orthanc_auth_service/permissions.json
restart: unless-stopped
environment:
ENABLE_KEYCLOAK: "true"
PUBLIC_ORTHANC_ROOT: "https://mydomain/orthanc/"
PUBLIC_LANDING_ROOT: "https://mydomain/orthanc/ui/app/token-landing.html"
PERMISSIONS_FILE_PATH: "/orthanc_auth_service/permissions.json"
ENABLE_KEYCLOAK_API_KEYS: "true"
SECRET_KEY: "secret"
KEYCLOAK_CLIENT_SECRET: "secret"
USERS: |
{
"secret": "secret"
}
keycloak:
image: orthancteam/orthanc-keycloak:24.5.1
depends_on: [keycloak-db]
restart: unless-stopped
environment:
KEYCLOAK_ADMIN: "admin"
KEYCLOAK_ADMIN_PASSWORD: "pwd"
KC_DB: "postgres"
KC_DB_URL: "jdbc:postgresql://keycloak-db:5432/keycloak"
KC_DB_USERNAME: "keycloak"
KC_DB_PASSWORD: "keycloak"
KC_HOSTNAME_URL: "https://mydomain/keycloak"
KC_HOSTNAME_ADMIN_URL: "https://mydomain/keycloak"
# env_file:
#- ./secrets/KEYCLOAK_ADMIN_PASSWORD.env
keycloak-db:
image: postgres:15
restart: unless-stopped
volumes: ["keycloak-db:/var/lib/postgresql/data"]
environment:
POSTGRES_PASSWORD: "keycloak"
POSTGRES_USER: "keycloak"
POSTGRES_DB: "keycloak"
volumes:
keycloak-db:
orthanc-data:
orthanc-index:
#secrets:
#orthanc-api.secret.json:
# file: secrets/orthanc-api.secret.json
#orthanc-ingest.secret.json:
# file: secrets/orthanc-ingest.secret.json
#orthanc-frontdesk.secret.json:
# file: secrets/orthanc-frontdesk.secret.json
#ostgres-azure.secret.json:
# file: secrets/postgres-azure.secret.json
#ORTHANC__AUTHORIZATION__WEB_SERVICE_PASSWORD:
# file: secrets/ORTHANC__AUTHORIZATION__WEB_SERVICE_PASSWORD
#SECRET_KEY:
# file: secrets/SECRET_KEY
#KEYCLOAK_CLIENT_SECRET:
# file: secrets/KEYCLOAK_CLIENT_SECRET
# test
The setup from the PDF might not be valid anymore since the images have changed …
A good starting point is this sample that should work “out of the box” + the orthanc-con repo for the SSL part
Hello, Alain, thank you for your response;
Right now i managed to make it work, for sure. But now, i need to access the API from my url. For ex, i want to access to https://mydomain.com/patients but it redirects me to the homepage of Orthanc, this happens with any url that i enter.
(Like: https://mydomain.com/dfsjfgoiufdjklfgjkldjlkg949354+)
In the Keycloak client config it doesn’t show any redirect uri for the homepage so, i’m lost…
Thanks for your time:)