适用场景
Scan GCP project posture with Prowler via a serverless Cloud Run Job triggered by Cloud Scheduler. One Terraform apply deploys to any number of projects and regions.
Scan GCP project posture with Prowler via a serverless Cloud Run Job triggered by Cloud Scheduler. One Terraform apply deploys to any number of projects and regions. 受众: Cloud engineers, security engineers, platform teams. 典型配置时长: 5 minutes.
Scan GCP project posture with Prowler via a serverless Cloud Run Job triggered by Cloud Scheduler. One Terraform apply deploys to any number of projects and regions.
复制开箱即用的入门配置,在您的环境中运行,然后返回此处查看详细的深度配置。
Demonstration only
This configuration is designed for ease of use. To deploy scanner clients at scale, please plan your deployment architecture accordingly or contact us for enterprise best practices.
Download the exact source files referenced on this page, or run the one-command installer to write them locally before following the deployment steps.
Creates the Terraform module under `deploy/gcp-cloud-scanner/` and prefills the current platform API URL so the Cloud Run deployment commands on this page work unchanged.
BLACKSHIELD_CLOUD_IMAGE=public.ecr.aws/blackshield-security/cloud-scanner:1.0.12 \
BLACKSHIELD_SITE_URL=https://blackshield.chaplau.com \
BLACKSHIELD_API_URL=https://api.blackshield.chaplau.com \
bash <(curl -fsSL https://blackshield.chaplau.com/source-bundles/gcp-cloud-scanner.sh)
cd deploy/gcp-cloud-scanner# Bootstrap the local source bundle first
bash <(curl -fsSL https://blackshield.chaplau.com/source-bundles/gcp-cloud-scanner.sh)
cd deploy/gcp-cloud-scanner
# Authenticate
gcloud auth application-default login
# Deploy all targets defined in main.tf locals.targets
TF_VAR_blackshield_api_key=sp_xxxx \
terraform init && terraform apply -auto-approve
# View deployed resources
terraform output -json cloud_run_job_names
terraform output -json scheduler_job_names# Trigger a one-off scan
gcloud run jobs execute blackshield-cloud-scanner \
--project my-prod-project \
--region us-central1
# Stream execution logs
gcloud logging read \
'resource.type="cloud_run_job" AND resource.labels.job_name="blackshield-cloud-scanner"' \
--project my-prod-project \
--limit 50 \
--format "table(timestamp,textPayload)"当您需要深度定制部署、验证资产归属或安全扩大部署范围时,请参考下方详细指引步骤。
步骤 1
Install Terraform, authenticate with gcloud, and set your API key.
达成目标状态
Set TF_VAR_blackshield_api_key=sp_xxxx in your environment.
步骤 2
Edit the targets map in main.tf, then apply to deploy all project+region pairs at once.
达成目标状态
Each project+region pair is an independent deployment unit.
步骤 3
Trigger a manual job execution and confirm findings arrive in the platform.
达成目标状态
Check terraform output for all deployed job and scheduler names.
Keep your rollout moving with the next recommended step.
导入首批发现