How to deploy multiple images (docker-compose) to a single URL in GCP

10/28/2020

I have been trying to deploy a dockerized REST API with DB (Postgres) and a Web Client (React) on GCP but I have completely confused myself at this point with how should I proceed regarding the deployment.

I am following the StephenGirder docker course on Udemy but it is based on AWS and not GCP.

I have 3 containers:

  • Web
  • API
  • Postgres

I have figured out that using Kubernetes would be an overkill and costly so I am trying to deploy the whole application without Kubernetes.

I use Nginx to route '/api/ path to the API container and / path to the Web container. I have given appropriate ports to the Web and API and it works fine locally.

TLDR: How am I supposed to deploy multi-container docker-compose images to a single URL in GCP?

-- Shubhankar Ranade
docker
docker-compose
hosting
kubernetes
nginx

0 Answers