fix(be-start): ensure that app + db are networked correctly
This commit is contained in:
parent
a90bfdea4c
commit
1648e09955
1 changed files with 7 additions and 3 deletions
|
@ -1,12 +1,15 @@
|
|||
#!/bin/bash
|
||||
|
||||
docker network create rotini-local || echo "Network already exists"
|
||||
|
||||
docker run \
|
||||
--name $DB_CONTAINER_NAME \
|
||||
-e POSTGRES_PASSWORD=$DATABASE_PASSWORD \
|
||||
-e POSTGRES_USER=$DATABASE_USER \
|
||||
-e POSTGRES_DB=$DATABASE_NAME \
|
||||
-e POSTGRES_PASSWORD=$DB_PASSWORD \
|
||||
-e POSTGRES_USER=$DB_USER \
|
||||
-e POSTGRES_DB=$DB_NAME \
|
||||
-v $DATABASE_STORAGE_PATH:/var/lib/postgresql/data \
|
||||
-p 5432:5432 \
|
||||
--network rotini-local \
|
||||
-d \
|
||||
postgres:15.4
|
||||
|
||||
|
@ -20,4 +23,5 @@ docker run \
|
|||
--publish 8000:8000 \
|
||||
--name $APP_CONTAINER_NAME \
|
||||
--env-file ../backend.env \
|
||||
--network rotini-local \
|
||||
rotini:dev
|
||||
|
|
Reference in a new issue