From b057da914ccd2080f9bc1d69494364cb23598070 Mon Sep 17 00:00:00 2001 From: Matthew Huntington Date: Sat, 2 Dec 2023 19:29:45 -0500 Subject: [PATCH] still working on postgres --- Dockerfile | 5 +++-- compose.yaml | 8 +++++++- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/Dockerfile b/Dockerfile index 122854d..5f18363 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,5 +1,6 @@ -FROM mahuntington/student:zsh +FROM mahuntington/student:postgres WORKDIR /home/student -CMD ["sudo", "pg_ctlcluster", "15", "main", "start"] +CMD ["pg_ctlcluster", "15", "main", "start", "--foreground"] +#RUN ["postgres", "-c", "max_connections=300"] diff --git a/compose.yaml b/compose.yaml index c3aaa75..b4fb11b 100644 --- a/compose.yaml +++ b/compose.yaml @@ -2,8 +2,14 @@ version: '3' services: student: - image: mahuntington/student:zsh + image: mahuntington/student:postgres command: /bin/sh stdin_open: true tty: true container_name: student + links: + - postgres + + postgres: + image: mahuntington/student:postgres + command: ["pg_ctlcluster", "15", "main", "start", "--foreground"]