The Simplest Way to Make Cloud Run and Zscaler Work Like They Should

Published
Length
3 min read

Luis Felipe Dias

All posts

You pair cloud run and zscaler by routing user traffic through private cloud connectors. This setup lets your team run web apps without opening public network ports. Cloud Run runs your containers on demand and scales them down to zero. Zscaler checks user identity and device posture before any traffic reaches your cloud. When you join them, users reach internal apps without a old-style network tunnel. Platform teams get one place to set access rules and read network logs. How cloud run and z

Your coding agents run with your access.

Claude Code reaches prod with a developer's credentials, and approval prompts get clicked through. hoop.dev checks every query, masks sensitive data, and holds risky changes for a human.

You pair cloud run and zscaler by routing user traffic through private cloud connectors. This setup lets your team run web apps without opening public network ports.

Cloud Run runs your containers on demand and scales them down to zero. Zscaler checks user identity and device posture before any traffic reaches your cloud. When you join them, users reach internal apps without a old-style network tunnel. Platform teams get one place to set access rules and read network logs.

How cloud run and zscaler handle logins and traffic

A request starts when a user opens an internal web address on a laptop. The local Zscaler client intercepts that request and checks the user login token. If the user passes the rule check, traffic moves to a private connector. That connector sits inside your Google Cloud virtual network and forwards the request. It sends the traffic over a private link to your serverless container.

Your container also needs a safe way to verify who sent the request. Teams set up Google Cloud to trust identity assertions from the upstream network. Each service runs under its own cloud service account with narrow database permissions. When the app queries a database, it uses that service account key. The response then travels back through the same private path to the user.

Common failure modes and how to scope network paths

Many teams make the mistake of leaving public ingress open on their containers. If you leave public ingress on, anyone can skip your Zscaler checks. You must set every internal service to accept traffic from private networks only. Another common risk comes from broad network segments inside the cloud project. When a connector can reach the whole network, one bad rule exposes everything.

Shared service accounts also create blind spots during security reviews and audits. If ten containers share one cloud role, you cannot tell which app ran a query. Worse, network logs only show the web request, not the database command inside. Give each container its own role with the bare minimum permissions to run. Place connectors in dedicated subnets and use firewall rules to limit their reach.

End-to-End Encryption: architecture patterns and best practices

Continue reading? Get the full guide.

Free. No spam. Unsubscribe anytime.

Auditing data queries and masking sensitive fields

Network edge rules protect the front door, but engineers still debug live apps. During an incident, a developer might query a production database or read logs. Edge logs only record that a user opened a web page or port. They do not record the exact query or the rows returned to the screen.

To pass strict audits, teams need visibility down to the exact command level. You also need data masking to protect private user details during routine work. Masking rewrites matched fields like emails, phone numbers, card numbers, and national IDs in results. This lets engineers fix bugs fast while keeping raw sensitive records off their screens.

Check database and API queries on the wire

Identity tools, roles, and network rules decide who opens a session. Setup alone cannot check what each query does or mask sensitive values in a response once a session starts. When workflows touch Postgres, MySQL, SQL Server, MongoDB, ClickHouse, Kubernetes APIs, SSH, or internal HTTP APIs, hoop.dev runs beside those services as an open-source proxy, a sidecar for your Postgres or API. It inspects requests coming in and results going back on the wire.

Your login details and client tools stay as they are while hoop.dev guardrails refuse bad deletes or drops before they run. On responses, hoop.dev data masking rewrites matched sensitive values in memory. Furthermore, hoop.dev holds SOC 2 Type II, is MIT licensed, and writes every query and decision to an audit trail that generates evidence for HIPAA, GDPR, and PCI DSS. See the source on GitHub.

Frequently asked questions

How do you block public traffic to a Cloud Run service?

Change the service ingress setting so it only accepts internal network traffic. This forces all requests to enter through your private virtual network and connector.

Should multiple Cloud Run services share one service account?

No, give each service its own dedicated account with narrow permissions. This stops one broken app from reading data that belongs to another app.

Does Zscaler log the database queries that a container runs?

No, Zscaler only logs the network connection between the user and the app. You need database audit logs to see the actual queries and results.

The query runs. The emails stay hidden.