I want to change the database location from the pgdata docker volume to explicitly live in a folder on my server. I first backed up the pgdata volume to an external hard drive to avoid mishaps. I then copied the contents of the pgdata volume to a folder where I want the database to be stored. I then updated the DB_DATA_LOCATION in the .env file to the new path.
I notived however, that in the docker compose file it still says
volumes: - pgdata:/var/lib/postgresql/data
volumes: - pgdata:/var/lib/postgresql/data
do I have to change the pgdata: to the new path on my server as well? I checked the docs and it only mentions DB_DATA_LOCATION.