Open jakublaz opened 5 months ago
One idea is to use bind mounts - copying a folder from container filesysten onto host filesystem
e.g for postgres it could be something like this:
volumes:
- type: bind
source: ./pg-save/
target: /var/lib/postgresql/data
Each database container will have a different target value which you can probably find on the internet
This soulution should work fine for preserving data on our own system. However, I do not think we should commit the database data and push it onto git This could cause many problems e.g. if we decide to change the way we push things onto the database instead.
Are not accessible from host filesystem (kept somewhere in Docker)
volumes:
- pgdata:/var/lib/postgresql/data
now when we close the app and delete all iamges or start a new one from new images the data is not saved so we can not store progress made or any data inserted