I'm trying to migrate lemmyfly.org to a server with more capacity at a different provider.
From the current running OK server I've downloaded the volumes folder using rsync. The new server is installed using ansible with success, all containers are up and running.
Then I stop the containers, rm volumes, copy the volumes from the backup location to the new server.
Now when trying to start the containers, the pictrs and postgres containers have errors. I noticed the volumes folder now have different owner (staff in stead of root).
So I manually changed ownership of those folders to root.
Now those containers can start ok. But now the lemmy container can't authenticate with postgres, although the password is all the same in the config files.
There must be an easier way to restore a backup. What am I missing ?
seems like I was nearly there :) yes you copy the volumes folder, and change ownership to those folders. But then the db has the password from your previous installation stored, so you need to change that. Copy the password from your docker-compose.yml file, and add it to the database like this: docker exec -i FOLDERNAME_postgres_1 psql -U lemmy -c "alter user lemmy with password 'bleh'"