mirror of
https://github.com/getredash/redash.git
synced 2025-12-19 17:37:19 -05:00
Automatically remove orphans when running make up (#7164)
This commit is contained in:
4
Makefile
4
Makefile
@@ -4,11 +4,11 @@ compose_build: .env
|
||||
COMPOSE_DOCKER_CLI_BUILD=1 DOCKER_BUILDKIT=1 docker compose build
|
||||
|
||||
up:
|
||||
docker compose up -d redis postgres
|
||||
docker compose up -d redis postgres --remove-orphans
|
||||
docker compose exec -u postgres postgres psql postgres --csv \
|
||||
-1tqc "SELECT table_name FROM information_schema.tables WHERE table_name = 'organizations'" 2> /dev/null \
|
||||
| grep -q "organizations" || make create_database
|
||||
COMPOSE_DOCKER_CLI_BUILD=1 DOCKER_BUILDKIT=1 docker compose up -d --build
|
||||
COMPOSE_DOCKER_CLI_BUILD=1 DOCKER_BUILDKIT=1 docker compose up -d --build --remove-orphans
|
||||
|
||||
test_db:
|
||||
@for i in `seq 1 5`; do \
|
||||
|
||||
Reference in New Issue
Block a user