Answer the question
In order to leave comments, you need to log in
How can I transfer a volume from a postgres database to another host without loss?
Good afternoon,
There is docker-compose.yml :
version: '3.7'
...
pgsql:
image: postgres:9.6-alpine
environment:
- POSTGRES_USER=${DB_USER}
- POSTGRES_PASSWORD=${DB_PASSWORD}
- POSTGRES_DATABASE=${DB_NAME}
ports:
- 54321:5432
volumes:
- ./storage/postgres:/var/lib/postgresql/data
docker compose-up --build -d
the folder is thrown, the site works, the data is migrated, saved. Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question