Skip to content

Commit

Permalink
Added missing file types in file_types enum and removed broken exactl…
Browse files Browse the repository at this point in the history
…yOneOf blocks in google_data_loss_prevention_job_trigger resource (#8100) (#5749)

Signed-off-by: Modular Magician <[email protected]>
  • Loading branch information
modular-magician authored Jun 8, 2023
1 parent ff8b48b commit 60cfad1
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 10 deletions.
3 changes: 3 additions & 0 deletions .changelog/8100.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
```release-note:enhancement
dlp: added missing file types `POWERPOINT` and `EXCEL` in `inspect_job.storage_config.cloud_storage_options.file_types` enum to `google_data_loss_prevention_job_trigger` resource
```
Original file line number Diff line number Diff line change
Expand Up @@ -509,6 +509,7 @@ resource "google_data_loss_prevention_job_trigger" "basic" {
file_set {
url = "gs://mybucket/directory/"
}
file_types = ["POWERPOINT", "EXCEL", "CSV", "TSV"]
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -301,10 +301,10 @@ Must be between 0 and 100, inclusively. Both 0 and 100 means no limit.`,
Optional: true,
Description: `List of file type groups to include in the scan. If empty, all files are scanned and available data
format processors are applied. In addition, the binary content of the selected files is always scanned as well.
Images are scanned only as binary if the specified region does not support image inspection and no fileTypes were specified. Possible values: ["BINARY_FILE", "TEXT_FILE", "IMAGE", "WORD", "PDF", "AVRO", "CSV", "TSV"]`,
Images are scanned only as binary if the specified region does not support image inspection and no fileTypes were specified. Possible values: ["BINARY_FILE", "TEXT_FILE", "IMAGE", "WORD", "PDF", "AVRO", "CSV", "TSV", "POWERPOINT", "EXCEL"]`,
Elem: &schema.Schema{
Type: schema.TypeString,
ValidateFunc: verify.ValidateEnum([]string{"BINARY_FILE", "TEXT_FILE", "IMAGE", "WORD", "PDF", "AVRO", "CSV", "TSV"}),
ValidateFunc: verify.ValidateEnum([]string{"BINARY_FILE", "TEXT_FILE", "IMAGE", "WORD", "PDF", "AVRO", "CSV", "TSV", "POWERPOINT", "EXCEL"}),
},
},
"files_limit_percent": {
Expand Down Expand Up @@ -596,7 +596,6 @@ is 1,024 characters.`,
},
},
},
ExactlyOneOf: []string{},
},
"job_notification_emails": {
Type: schema.TypeList,
Expand All @@ -606,7 +605,6 @@ is 1,024 characters.`,
Elem: &schema.Resource{
Schema: map[string]*schema.Schema{},
},
ExactlyOneOf: []string{},
},
"pub_sub": {
Type: schema.TypeList,
Expand All @@ -622,7 +620,6 @@ is 1,024 characters.`,
},
},
},
ExactlyOneOf: []string{},
},
"publish_findings_to_cloud_data_catalog": {
Type: schema.TypeList,
Expand All @@ -632,7 +629,6 @@ is 1,024 characters.`,
Elem: &schema.Resource{
Schema: map[string]*schema.Schema{},
},
ExactlyOneOf: []string{},
},
"publish_summary_to_cscc": {
Type: schema.TypeList,
Expand All @@ -642,7 +638,6 @@ is 1,024 characters.`,
Elem: &schema.Resource{
Schema: map[string]*schema.Schema{},
},
ExactlyOneOf: []string{},
},
"publish_to_stackdriver": {
Type: schema.TypeList,
Expand All @@ -652,7 +647,6 @@ is 1,024 characters.`,
Elem: &schema.Resource{
Schema: map[string]*schema.Schema{},
},
ExactlyOneOf: []string{},
},
"save_findings": {
Type: schema.TypeList,
Expand Down Expand Up @@ -712,7 +706,6 @@ Only for use with external storage. Possible values: ["BASIC_COLUMNS", "GCS_COLU
},
},
},
ExactlyOneOf: []string{},
},
},
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1047,7 +1047,7 @@ The following arguments are supported:
List of file type groups to include in the scan. If empty, all files are scanned and available data
format processors are applied. In addition, the binary content of the selected files is always scanned as well.
Images are scanned only as binary if the specified region does not support image inspection and no fileTypes were specified.
Each value may be one of: `BINARY_FILE`, `TEXT_FILE`, `IMAGE`, `WORD`, `PDF`, `AVRO`, `CSV`, `TSV`.
Each value may be one of: `BINARY_FILE`, `TEXT_FILE`, `IMAGE`, `WORD`, `PDF`, `AVRO`, `CSV`, `TSV`, `POWERPOINT`, `EXCEL`.

* `sample_method` -
(Optional)
Expand Down

0 comments on commit 60cfad1

Please sign in to comment.