I've configured a little cluster using docker-compose, consisting of parse-server, mongo and parse-dashboard:
version: "3"
services:
myappdb:
image: mongo
ports:
- 27017:27017
myapp-parse-server:
image: parseplatform/parse-server
environment:
- PARSE_SERVER_MASTER_KEY=xxxx
- PARSE_SERVER_APPLICATION_ID=myapp
- VERBOSE=0
- PARSE_SERVER_DATABASE_URI=mongodb://myappdb:27017/dev
- PARSE_SERVER_URL=http://myapp-parse-server:1337/parse
depends_on:
- myappdb
ports:
- 5000:1337
parse-dashboard:
image: parseplatform/parse-dashboard
ports:
- 5001:4040
environment:
- PARSE_DASHBOARD_ALLOW_INSECURE_HTTP=1
- PARSE_DASHBOARD_SERVER_URL=http://myapp-parse-server:1337/parse
- PARSE_DASHBOARD_APP_ID=myapp
- PARSE_DASHBOARD_MASTER_KEY=xxxx
- PARSE_DASHBOARD_USER_ID=admin
- PARSE_DASHBOARD_USER_PASSWORD=xxxx
Try as I might, however, I cannot get the deployed parse-dashboard to connect to the myapp-parse-server. After I log in to the dashboard using my browser (at localhost:5001), the dashboard app informs me that it is 'unable to connect to server'.
I've tried pinging the host 'myapp-parse-server' from the parse-dashboard container, and it can see the container just fine. Similarly, it can see the endpoint http://myapp-parse-server:1337/parse; wget returns the expected 403.
If I use a copy of parse-dashboard running on my host machine, it works just fine against http://localhost:5000/parse. So the forwarded port from my host to the parse-server works.
I've also tried configuring dashboard using parse-dashboard-config.json mounted into the container. Yields exactly the same result.
I'm at a loss as to what I'm doing wrong here. Can anybody shed some light on this?