KeyCloak docker-compose import realm file
Example of docker-compose for keycloak 18 with ability to import a realm file:It assumes the realm 2022-7-17 02:55:0 Author: blog.gtiwari333.com(查看原文) 阅读量:293 收藏

Example of docker-compose for keycloak 18 with ability to import a realm file:

It assumes the realm-export.json file is in /PATH_OF_realm-export.json_FILE/

docker-compose.yml:

version: '3'
services:
keycloak:
image: 'quay.io/keycloak/keycloak:18.0.2'
container_name: keycloak
command: [ 'start-dev --import-realm' ]
environment:
- KEYCLOAK_DB=dev-file
- KEYCLOAK_ADMIN=admin
- KEYCLOAK_ADMIN_PASSWORD=admin
- KEYCLOAK_FEATURES=scripts
- KEYCLOAK_HTTP_PORT=8080
volumes:
- /PATH_OF_realm-export.json_FILE/:/opt/keycloak/data/import
ports:
- 8082:8080

文章来源: http://blog.gtiwari333.com/2022/07/keycloak-docker-compose-import-realm.html
如有侵权请联系:admin#unsafe.sh