File tree Expand file tree Collapse file tree 1 file changed +28
-0
lines changed Expand file tree Collapse file tree 1 file changed +28
-0
lines changed Original file line number Diff line number Diff line change
1
+ # This file is ONLY for running the database on your local machine
2
+ # for development tasks like running migrations.
3
+
4
+ services :
5
+ db :
6
+ image : postgres:15-alpine
7
+ # We use the same container name as production for consistency.
8
+ container_name : codebuilder-postgres-db
9
+ restart : unless-stopped
10
+ env_file :
11
+ - ./.env
12
+ ports :
13
+ # This maps your local machine's port 5434 to the container's port 5432.
14
+ # You can connect to this from your local machine if needed.
15
+ - " 5434:5432"
16
+ volumes :
17
+ # Persists data in a local volume named 'postgres-data-local'
18
+ - postgres-data-local:/var/lib/postgresql/data
19
+ networks :
20
+ # Connects to the same network so your app can find it at 'db:5432'
21
+ - codebuilder-net
22
+
23
+ volumes :
24
+ postgres-data-local :
25
+
26
+ networks :
27
+ codebuilder-net :
28
+ name : codebuilder-net
You can’t perform that action at this time.
0 commit comments