NORY-36: add Ory Keto to Docker Compose setup
This commit is contained in:
parent
9a44023b70
commit
07c0d3b696
3 changed files with 80 additions and 0 deletions
|
@ -70,6 +70,39 @@ services:
|
|||
networks:
|
||||
- internal
|
||||
|
||||
ory-keto-migrate:
|
||||
container_name: ory-keto-migrate
|
||||
image: oryd/keto:v0.12.0
|
||||
restart: on-failure
|
||||
volumes:
|
||||
- ./ory/keto:/etc/config/keto
|
||||
- ory-keto-data:/home/ory
|
||||
- ory-keto-data:/var/lib/sqlite
|
||||
command: migrate -c /etc/config/keto/keto.yaml up --yes
|
||||
depends_on:
|
||||
ory-postgres:
|
||||
condition: service_healthy
|
||||
networks:
|
||||
- internal
|
||||
|
||||
|
||||
ory-keto:
|
||||
container_name: ory-keto
|
||||
image: oryd/keto:v0.12.0
|
||||
restart: unless-stopped
|
||||
ports:
|
||||
- 127.0.0.1:4466:4466 # public
|
||||
- 127.0.0.1:4467:4467 # admin
|
||||
volumes:
|
||||
- ./ory/keto:/etc/config/keto
|
||||
- ory-keto-data:/home/ory
|
||||
- ory-keto-data:/var/lib/sqlite
|
||||
command: serve -c /etc/config/keto/keto.yaml all
|
||||
depends_on:
|
||||
ory-keto-migrate:
|
||||
condition: service_completed_successfully
|
||||
networks:
|
||||
- internal
|
||||
|
||||
ory-mailslurper:
|
||||
container_name: ory-mailslurper
|
||||
|
@ -111,4 +144,5 @@ networks:
|
|||
volumes:
|
||||
ory-kratos-data:
|
||||
ory-hydra-data:
|
||||
ory-keto-data:
|
||||
ory-postgres-data:
|
||||
|
|
43
docker/ory-dev/ory/keto/keto.yaml
Normal file
43
docker/ory-dev/ory/keto/keto.yaml
Normal file
|
@ -0,0 +1,43 @@
|
|||
#
|
||||
# Documentation: https://www.ory.sh/docs/keto/reference/configuration
|
||||
# Configuration UI: https://www.ory.sh/docs/keto/reference/configuration-editor
|
||||
#
|
||||
|
||||
#
|
||||
# Configure the Keto logging
|
||||
#
|
||||
log:
|
||||
level: info
|
||||
format: text
|
||||
leak_sensitive_values: true
|
||||
|
||||
#
|
||||
# Configure the datasource. Alternative for development purposes is 'memory' (not persistent!)
|
||||
#
|
||||
dsn: postgres://postgres:postgres@ory-postgres:5432/keto?sslmode=disable&max_conns=20&max_idle_conns=4
|
||||
|
||||
#
|
||||
# Set the required namespaces
|
||||
#
|
||||
namespaces:
|
||||
- id: 0
|
||||
name: roles
|
||||
|
||||
serve:
|
||||
read:
|
||||
host: 0.0.0.0
|
||||
port: 4466
|
||||
cors:
|
||||
enabled: true
|
||||
allowed_origins:
|
||||
- http://localhost:3000
|
||||
- http://localhost:4000
|
||||
|
||||
write:
|
||||
host: 0.0.0.0
|
||||
port: 4467
|
||||
cors:
|
||||
enabled: true
|
||||
allowed_origins:
|
||||
- http://localhost:3000
|
||||
- http://localhost:4000
|
|
@ -3,3 +3,6 @@ GRANT ALL PRIVILEGES ON DATABASE kratos TO postgres;
|
|||
|
||||
CREATE DATABASE hydra;
|
||||
GRANT ALL PRIVILEGES ON DATABASE hydra TO postgres;
|
||||
|
||||
CREATE DATABASE keto;
|
||||
GRANT ALL PRIVILEGES ON DATABASE keto TO postgres;
|
||||
|
|
Loading…
Add table
Reference in a new issue