FWIW, I'm running NixOS but gave up on running the Lemmy module. I gave up when I realized that Lemmy seems to need superuser access to the Postgresql server, to install plugins or whatever.
So instead, I used Arion to make a docker-compose image, running in podman. Works great so far.