Hi,
Hi,
I have been trying to setup a self-hosted langfuse server. I followed the instructions on https://langfuse.com/docs/deployment/self-host. I installed postgresql (on docker as well) and verified that it works.
Docker run returns following output:
I even tried another solution listed above by replacing host
localhost
with host.docker.internal
, but this did not help.
any ideas how to resolve this? thanks in advance!6 Replies
hi, are you running a docker compose on a single server that hosts the db and the langfuse app ?
Yes, I'm running it on a single VM.
okay then the host in the DATABASE_URL should not be localhost but the name of the docker service running the db
you can send the docker compose file (removing confidential information first) so i can help you better
Replacing it with my postgres image name (
postgresdb
) did not help, I got the same issue.
I just ran the original postgres-alpine image with the below config, as such I didn't have to write a docker compose file.
After running the postgres db, I ran the following command to get langfuse up.
This is my VM architecture info:
Linux office-ml-training 6.1.0-17-cloud-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.69-1 (2023-12-30) x86_64 GNU/Linux
My password and username also don't contain any special characters, which was apparently an issue with prisma for some people.
The issue was with the networks the containers were in. Once I created a new network and added both containers to same network, it started working.
Thanks for your help @Bryan .Thank you @Brijesh and @Bryan for debugging this & sharing the solution here so transparently!
Oh yeah the network is necessary to have your docker containers communicate between each other ! I'm glad you managed to find the solution @Brijesh