N
N
Nikita M.2021-04-10 14:13:38
PostgreSQL
Nikita M., 2021-04-10 14:13:38

How not to break the database in docker?

Hello, there is a django project using postgres database. Both are running on docker, built using docker-compose.
Question: how can I upload an update to the project without breaking or damaging the database? (without deleting it)
What do the containers look like (docker ps -a):

CONTAINER_ID IMAGE CREATED STATUS PORTS NAMES
123321f backend_server 60 days ago up - backend_server_
123321f postgres:10 60 days ago up - database_1

Answer the question

In order to leave comments, you need to log in

1 answer(s)
V
Vasily Bannikov, 2021-04-10
@vabka

data must be stored on an external VOLUME, which is mounted to the
container

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question