Hello! I'm running into some trouble using SuperTo...
# support-questions
h
Hello! I'm running into some trouble using SuperTokens in a docker setup. My app service is trying to connect to my supertokens service on localhost:3567, but I'm seeing this error in the console.log. Any suggestions?
r
Hey!
Are you using localhost as the connectionURI? Iā€™m a little confused about your setup
h
Hi! Yes, that's what I'm attempting to do šŸ™‚
r
Right. And the backend is running inside docker too?
h
Docker compose looks like this: version: '3.8' services: app: image: server-dev build: . ports: - 3000:3000 volumes: - ./pages:/app/pages - ./public:/app/public - ./styles:/app/styles - ./config:/app/config supertokens: image: registry.supertokens.io/supertokens/supertokens-mysql ports: - 3567:3567 db: platform: linux/x86_64 image: mysql:8.0 cap_add: - SYS_NICE restart: always environment: - MYSQL_DATABASE=db - MYSQL_ROOT_PASSWORD=password ports: - 3306:3306 volumes: - db:/var/lib/mysql - ./db/init.sql:/docker-entrypoint-initdb.d/init.sql volumes: db: driver: local
Yup! I'm pretty new to docker concepts, so if there's a better way/different setup you'd suggest I'm all ears
r
Right I see. So if you use localhost inside a docker container, it points to inside that container and not your machine
You may want to do some reading about docker networks
h
Ahh, thanks so much -- sorry to bug you with what is essentially just a docker question! Appreciate the help!
r
Happy to help šŸ™‚