Fix race condition between kratos-migrate and migrate-admindb

migrate-admindb service in docker compose must require all kratos
migrations to be completed, otherwise it fails with some-kratos-table
not exists error.

Fix #66

Signed-off-by: Akshay Gaikwad <akshay.gaikwad@rafay.co>
This commit is contained in:
Akshay Gaikwad
2022-03-16 18:50:45 +05:30
parent bb3d785756
commit 14ef1afd00
+2 -1
View File
@@ -39,7 +39,8 @@ services:
migrate-admindb:
depends_on:
- kratos-migrate
kratos-migrate:
condition: service_completed_successfully
image: migrate/migrate:v4.15.1
restart: on-failure
command: -path=/migrations/admindb -database postgres://$DB_USER:$DB_PASSWORD@postgresd:$DB_PORT/$DB_NAME?sslmode=disable up