*thread*: Has anyone got the prisma with mongodb t...
# orm-help
j
thread: Has anyone got the prisma with mongodb to work on a window 10 machine. I followed the Prisma 1.22 setup instructions and I can't run prisma deploy
Here is the error I am getting: Could not connect to server at http://localhost:4466. Please check if your server is running.
p
Are you using docker-compose to spin up the prisma service?
j
Yes let me post that up
Copy code
version: '3'
services:
  prisma:
    image: prismagraphql/prisma:1.22
    restart: always
    ports:
    - "4466:4466"
    environment:
      PRISMA_CONFIG: |
        port: 4466
        databases:
          default:
            connector: mongo
            host: host.docker.internal
            uri: <mongodb://prisma:prisma@mongo>
  mongo:
    image: mongo:3.6
    restart: always
    environment:
      MONGO_INITDB_ROOT_USERNAME: prisma
      MONGO_INITDB_ROOT_PASSWORD: prisma
    ports:
      - "27017:27017"
    volumes:
      - mongo:/var/lib/mongo
volumes:
  mongo:
p
Try to add mongo service before prisma and add depends_on property for prisma service. I have attached my configuration which is working.
j
So I gave your configuration a try same result I tried my whole set up on my linux machine and it worked perfectly. That confirms its something between docker and windows. Thank you for your help
p
Are you able to access http://localhost:4466 through the browser?
j
Not on my window computer i have to hit the VM default IP http://192.168.99.100:4466
p
Have you tried changing the endpoint value to http://192.168.99.100:4466 in prisma.yml?
j
I have resolved the issue. Localhost does not seem to work on Docker Toolbox. I had to upgrade my stuff to Docker for Windows in order for localhost to work properly. Thank you for helping I really appreciate it
p
Ah, no problem. I got to learn something new 🙂