Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

API OIDC authentication mechanism #10905

Open
wants to merge 17 commits into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
39 changes: 19 additions & 20 deletions docker-compose-dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,12 @@ services:
ENABLE_RELOAD: "1"
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm just putting this here at the top but can we please get a release note snippet?

SKIP_DEPLOY: "${SKIP_DEPLOY}"
DATAVERSE_JSF_REFRESH_PERIOD: "1"
DATAVERSE_FEATURE_API_BEARER_AUTH: "1"
ErykKul marked this conversation as resolved.
Show resolved Hide resolved
DATAVERSE_MAIL_SYSTEM_EMAIL: "dataverse@localhost"
DATAVERSE_MAIL_MTA_HOST: "smtp"
DATAVERSE_AUTH_OIDC_ENABLED: "1"
DATAVERSE_AUTH_OIDC_CLIENT_ID: test
DATAVERSE_AUTH_OIDC_CLIENT_SECRET: 94XHrfNRwXsjqTqApRrwWmhDLDHpIYV8
DATAVERSE_AUTH_OIDC_AUTH_SERVER_URL: http://keycloak.mydomain.com:8090/realms/test
ErykKul marked this conversation as resolved.
Show resolved Hide resolved
DATAVERSE_AUTH_API_OIDC_CLIENT_ID: oauth2-proxy
DATAVERSE_AUTH_API_OIDC_CLIENT_SECRET: 72341b6d-7065-4518-a0e4-50ee15025608
DATAVERSE_AUTH_API_OIDC_PROVIDER_URI: http://172.17.0.1:9080/realms/oauth2-proxy
ErykKul marked this conversation as resolved.
Show resolved Hide resolved
DATAVERSE_AUTH_API_OIDC_REDIRECT_URI: http://localhost:8080/api/v1/callback/token
DATAVERSE_SPI_EXPORTERS_DIRECTORY: "/dv/exporters"
# These two oai settings are here to get HarvestingServerIT to pass
dataverse_oai_server_maxidentifiers: "2"
Expand Down Expand Up @@ -164,24 +163,24 @@ services:
tmpfs:
- /mail:mode=770,size=128M,uid=1000,gid=1000

dev_keycloak:
container_name: "dev_keycloak"
image: 'quay.io/keycloak/keycloak:21.0'
keycloak:
ErykKul marked this conversation as resolved.
Show resolved Hide resolved
container_name: keycloak
image: keycloak/keycloak:25.0
hostname: keycloak
command:
- 'start-dev'
ErykKul marked this conversation as resolved.
Show resolved Hide resolved
- '--http-port=9080'
- '--import-realm'
volumes:
- ./keycloak:/opt/keycloak/data/import
environment:
- KEYCLOAK_ADMIN=kcadmin
- KEYCLOAK_ADMIN_PASSWORD=kcpassword
- KEYCLOAK_LOGLEVEL=DEBUG
- KC_HOSTNAME_STRICT=false
networks:
dataverse:
aliases:
- keycloak.mydomain.com #create a DNS alias within the network (add the same alias to your /etc/hosts to get a working OIDC flow)
command: start-dev --import-realm --http-port=8090 # change port to 8090, so within the network and external the same port is used
KC_HTTP_PORT: 9080
ErykKul marked this conversation as resolved.
Show resolved Hide resolved
KEYCLOAK_ADMIN: [email protected]
ErykKul marked this conversation as resolved.
Show resolved Hide resolved
KEYCLOAK_ADMIN_PASSWORD: password
ports:
- "8090:8090"
volumes:
- './conf/keycloak/test-realm.json:/opt/keycloak/data/import/test-realm.json'
- 9080:9080
networks:
- dataverse

ErykKul marked this conversation as resolved.
Show resolved Hide resolved
# This proxy configuration is only intended to be used for development purposes!
# DO NOT USE IN PRODUCTION! HIGH SECURITY RISK!
Expand Down
Loading
Loading