many-garden-6507
06/09/2022, 6:19 AMfreezing-solstice-24704
06/13/2022, 5:27 PMketo.yaml
config file you should see a key/value dsn: memory
. This is saying that the datasource will be in memory. This value is overridden by the env var DSN
. In order to get Keto to store the relations to a database, you will need a few things:
• In your docker-compose file under the keto service you will need the following (but configured for your database):
environment:
- DSN=<postgres://username:password@postgres-database:5432/keto?sslmode=disable>
• You will also need to setup Keto migrate by adding a new entry into your docker-compose using the following (replacing any necessary values for your environment such as network and volumes):
keto-migrate:
container_name: ory-keto-migrate
depends_on:
- postgres-database
image: oryd/keto:v0.8.0-alpha.2
environment:
- DSN=<postgres://username:password@postgres-database:5432/keto?sslmode=disable>
- LOG_LEVEL=trace
volumes:
- type: bind
source: ./keto/config
target: /etc/config/keto
command:
[
'migrate',
'up',
'-c',
'/etc/config/keto/keto.yml',
'-y'
]
restart: on-failure
networks:
- yournetworkhere
freezing-solstice-24704
06/13/2022, 5:29 PMoryd/keto:v0.7.0-alpha.1-sqlite
to something like oryd/keto:v0.8.0-alpha.2