From 2eda99cd21964636555c1f77577e9857149e9785 Mon Sep 17 00:00:00 2001 From: Cynthia Kiser Date: Wed, 28 Aug 2024 10:25:28 -0700 Subject: [PATCH] Updated Postgres container to match what bakerydemo uses when running separately Added a make target to remove the pg data volume; this will make it easier for people to upgrade PG --- Makefile | 3 +++ docker-compose.yml | 8 ++++---- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/Makefile b/Makefile index 9180948..d85af43 100644 --- a/Makefile +++ b/Makefile @@ -31,6 +31,9 @@ ssh-wagtail: ## Enter the running Docker container for the wagtail development e ssh-db: ## Open a PostgreSQL shell session docker compose exec web python manage.py dbshell +destroy-db: ## Remove the volume containing the PostgreSQL data + docker volume rm docker-wagtail-develop_postgres-data + down: ## Stop and remove all Docker containers docker compose down diff --git a/docker-compose.yml b/docker-compose.yml index 341cd11..ed4f76c 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -1,9 +1,7 @@ -version: '3' - volumes: postgres-data: node_modules: - + services: web: container_name: "web" @@ -23,9 +21,10 @@ services: depends_on: - db - frontend + db: container_name: "db" - image: postgres:12.3-alpine + image: postgres:14.1 environment: POSTGRES_USER: wagtail POSTGRES_DB: wagtail @@ -35,6 +34,7 @@ services: restart: "no" expose: - "5432" + frontend: container_name: "frontend" build: