From cf1a2d4f51e48e14d5426ba024088f6f5d7f7449 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alessandro=20Pezz=C3=A8?= Date: Sat, 13 Feb 2021 19:27:58 +0100 Subject: [PATCH] chore: update sprites/add make command to destroy the db fix: run flush non interactively --- Makefile | 8 ++++++-- data/v2/sprites | 2 +- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index 8da719e6..b36ea57a 100755 --- a/Makefile +++ b/Makefile @@ -49,8 +49,12 @@ docker-build-db: # (Docker) Build the database docker-make-migrations: # (Docker) Create migrations files if schema has changed docker-compose exec -T app sh -c 'python manage.py makemigrations ${docker_config}' -docker-flush-db: # (Docker) Removes all the data present in the database - docker-compose exec -T app sh -c 'python manage.py flush ${docker_config}' +docker-flush-db: # (Docker) Removes all the data present in the database but preserves tables and migrations + docker-compose exec -T app sh -c 'python manage.py flush --no-input ${docker_config}' + +docker-destroy-db: # (Docker) Removes the volume where the database is installed on, alongside to the container itself + docker rm -f pokeapi_db_1 + docker volume rm pokeapi_pg_data docker-shell: # (Docker) Launch an interative shell for the pokeapi container docker-compose exec app sh -l diff --git a/data/v2/sprites b/data/v2/sprites index 897eaefa..e24fdb77 160000 --- a/data/v2/sprites +++ b/data/v2/sprites @@ -1 +1 @@ -Subproject commit 897eaefad787da88a5ad6b0cdce833360f9f8163 +Subproject commit e24fdb772a7568d06081645034fc03afb420ec1b