I'm running Docker containers on a Google Cloud instance using Docker Compose. Here is the instance:
And here are the containers running:
$ docker-compose up -d db graphql api
Creating mobydq-db ... done
Creating mobydq-graphql ... done
Creating mobydq-api ... done
$ docker ps -a
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
05dae8c9340d mobydq-api "flask run --host=0.…" 5 seconds ago Up 4 seconds 0.0.0.0:5434->5434/tcp mobydq-api
30d6b7a6725e graphile/postgraphile "postgraphile -n 0.0…" 6 seconds ago Up 5 seconds 5000/tcp, 0.0.0.0:5433->5433/tcp mobydq-graphql
85c4e42e27fd mobydq-db "docker-entrypoint.s…" 6 seconds ago Up 5 seconds 5432/tcp mobydq-db
Two of these containers are supposed to be reachable at the following addresses:
- http://35.220.221.20:5434/mobydq/api/doc (Swagger doc generated with Falsk Restplus)
- http://35.220.221.20:5433/graphiql (GraphiQL doc generated by PostGraphile)
I also have firewall rules configured to ensure these ports are accessible from the internet:
Still, I'm unable to reach the two pages above from my browser. What am I missing?
I was installing my application in the Google Cloud Shell (1) instead of doing it on a Shell session connected to my VM instance (2).