google_security_scanner_scan_config

A ScanConfig resource contains the configurations to launch a scan.

To get more information about ScanConfig, see:

Open in Cloud Shell

Example Usage - Scan Config Basic

resource "google_compute_address" "scanner_static_ip" {
  provider = google-beta
  name     = "scan-basic-static-ip"
}

resource "google_security_scanner_scan_config" "scan-config" {
  provider         = google-beta
  display_name     = "terraform-scan-config"
  starting_urls    = ["http://${google_compute_address.scanner_static_ip.address}"]
  target_platforms = ["COMPUTE"]
}

Argument Reference

The following arguments are supported:


The authentication block supports:

The google_account block supports:

The custom_account block supports:

The schedule block supports:

Attributes Reference

In addition to the arguments listed above, the following computed attributes are exported:

Timeouts

This resource provides the following Timeouts configuration options:

Import

ScanConfig can be imported using any of these accepted formats:

In Terraform v1.5.0 and later, use an import block to import ScanConfig using one of the formats above. For example:

import {
  id = "projects/{{project}}/scanConfigs/{{name}}"
  to = google_security_scanner_scan_config.default
}

When using the terraform import command, ScanConfig can be imported using one of the formats above. For example:

$ terraform import google_security_scanner_scan_config.default projects/{{project}}/scanConfigs/{{name}}
$ terraform import google_security_scanner_scan_config.default {{project}}/{{name}}
$ terraform import google_security_scanner_scan_config.default {{name}}

User Project Overrides

This resource supports User Project Overrides.