Get hands-on experience with 20+ free Google Cloud products and $300 in free credit for new customers.

How do I set up a Cloud Run to communicate through our internal VPN using a custom URL

In GCP, we would like to connect to a Cloud Run application through our internal network using a custom URL.

We have a cloud run answering on a custom URL, externally. We are using an IPsec VPN to connect to GCP internally. We have a Private Service Connect set up with an IP address that I can ping and route correctly through our network.

I set the application in Cloud Run to internal traffic only. I set up the run.app domain in our local DNS and set up the host with the internal IP address of the Private Service Connect, I am able to connect to the application. I set up the DNS for the host of the custom URL to the internal IP address of the Private Service Connect, the custom URL does not work.

I am getting a little lost on what my next steps are. What should I be using to get the custom URLs to work correctly?

0 5 1,794
5 REPLIES 5

Hi @Patrickermer ,

Can you add details to your question? 

1. Screenshot of the error when you try to the Cloud Run application.
2. Screenshot of your setup for the DNS records.
3. Documentations or guides that you have followed (if any).

Hi @Marvin_Lucero ,

Please see screen shots as requested.

I do not know which documents we followed to set this up.  We have been working on this project for a few months, and I was only recently brought in for the networking part of this setup.

DNS.pngURL Error.png

Hi @Patrickermer ,

I checked your custom url "phoenix-dev.species360.org", it's already accessible. It may have been it's still propagating the time when you're seeing the 404 error. 

Hi @Marvin_Lucero ,

Thank you very much. 

Yes, phoenix-dev.species360.org is accessible to the internet.  This is what I'm trying to turn off.

When I set the Cloud Run to Internal, and route the traffic through our IPSec VPN connection, which uses the Private Service Connect, then I get the 404 error.  This is the problem I'm trying to solve.   I set this up after the domain name was completely propagated.

Hi, 
Did You find solution for this configuration?