The Simplest Way to Make AWS Backup and Cloud Run Work Like They Should
Using aws backup and cloud run lets teams run recovery tasks across both clouds. A container on Google Cloud can trigger and check storage snapshots inside Amazon. Multi-cloud teams often run stateless services on Google Cloud while keeping data in Amazon. Linking these two services lets you automate backup checks and test restores on demand. You do not need to manage extra virtual machines just to run backup scripts. Instead, your container wakes up, calls the backup service, and shuts down wh
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.
Using aws backup and cloud run lets teams run recovery tasks across both clouds. A container on Google Cloud can trigger and check storage snapshots inside Amazon.
Multi-cloud teams often run stateless services on Google Cloud while keeping data in Amazon. Linking these two services lets you automate backup checks and test restores on demand. You do not need to manage extra virtual machines just to run backup scripts. Instead, your container wakes up, calls the backup service, and shuts down when done.
How aws backup and cloud run share identity and data
The safest way to link these services is through workload identity federation. Your Google service account presents an identity token to the Amazon identity service. Amazon checks this token and trades it for temporary role keys. Your container never stores static keys on disk or in secret stores. This stops key leaks before they can happen.
Once the container has temporary keys, it calls the Amazon backup endpoints over HTTPS. The container can start an on-demand backup job or check a restore task. Data does not need to move between clouds during a simple status check. If your container needs to read restored files, it pulls them over TLS. You can also route this traffic through a private cross-cloud network link.
Event notifications help connect the two platforms in the other direction. When a backup finishes, Amazon can send a message to a webhook. That webhook wakes up the Google container to run a data check. The container verifies the restored snapshot and logs the result for your team. After the test passes, the container tells Amazon to delete the test restore.
Common failure modes and how to scope roles
Many teams start by putting long-lived Amazon keys inside container variables. This is a major risk if a developer logs the container state. Shared service accounts also create problems when multiple apps use the same identity. If one container is compromised, the attacker gets broad rights across your backups. Broad tokens often allow deleting recovery points instead of just starting new jobs.
Unlogged calls between clouds make incident reviews very hard for security teams. If a script deletes a backup vault, you must know which container did it. When every container shares one static key, the cloud logs show only one user. You lose track of which person or build triggered the container run. You also face trouble if data Masking is missing during restore checks. Masking rewrites matched fields like emails, phone numbers, card numbers, or national IDs in results.
AWS CloudTrail + End-to-End Encryption: architecture patterns and best practices
Continue reading? Get the full guide.
Free. No spam. Unsubscribe anytime.
You can fix these issues by scoping each role to one clear task. Give the status container rights only to read job states and list vaults. Give the restore test container rights only to restore into an isolated test account. Block all roles from deleting production recovery points by adding strict vault lock rules. Always set a short time limit on the temporary role sessions.
Setting up safe cross-cloud restore checks
Good backups are useless if you never test your restore process. You can use a scheduled job on Google to run weekly restore drills. The scheduler starts your container, which then requests a test restore in Amazon. Once the data is ready, the container runs a quick check on the records.
Keep your network paths tight when running these cross-cloud checks. Set your container egress rules so traffic only goes to known cloud endpoints. Log every API call on both clouds so your audit trail stays complete. This setup gives you clean automation and strong security across both platforms.
Add runtime guardrails and masking beside your databases and APIs
Login rules, role grants, and CI checks govern who connects to your stack. Yet any allowed script, engineer, or AI agent still runs commands with the full scope of its role. For workloads on Postgres, MySQL, SQL Server, MongoDB, ClickHouse, Kubernetes, SSH, or internal HTTP services, hoop.dev sits beside the service as an open-source proxy, a sidecar for your database or API.
Before a query runs, hoop.dev guardrails check the statement against your rules. An AI Analyzer you configure can score intent or hold risky calls for human review. Next, hoop.dev data masking rewrites sensitive fields in responses, and each verdict is logged per listener. Explore the MIT-licensed project on GitHub.
Frequently asked questions
How does Cloud Run log in to AWS Backup without static keys?
It uses identity federation to trade a Google token for temporary Amazon role keys. This lets the container make signed calls without storing any secret keys.
Can AWS Backup trigger a Cloud Run service when a job finishes?
Yes, Amazon event rules can send an HTTPS message to your container endpoint. Your service wakes up, checks the message signature, and runs your follow-up task.
How do we stop a compromised container from deleting backups?
Use separate roles with narrow permissions and turn on backup vault locks. Do not grant delete rights to the role that your container uses.
Related guides
In this post