From 5e8e12c22dd2c57f761399649126c593735a5200 Mon Sep 17 00:00:00 2001 From: Salim Afiune Maya Date: Wed, 23 Nov 2022 08:53:10 -0800 Subject: [PATCH] docs: add limit_by_label examples Signed-off-by: Salim Afiune Maya --- .../r/integration_docker_hub.html.markdown | 18 +++++++++ .../r/integration_docker_v2.html.markdown | 18 +++++++++ website/docs/r/integration_ecr.html.markdown | 18 +++++++++ website/docs/r/integration_gar.html.markdown | 40 +++++++++---------- website/docs/r/integration_gcr.html.markdown | 18 +++++++++ website/docs/r/integration_ghcr.html.markdown | 18 +++++++++ 6 files changed, 108 insertions(+), 22 deletions(-) diff --git a/website/docs/r/integration_docker_hub.html.markdown b/website/docs/r/integration_docker_hub.html.markdown index 1c1bf79c..70482fd9 100644 --- a/website/docs/r/integration_docker_hub.html.markdown +++ b/website/docs/r/integration_docker_hub.html.markdown @@ -40,6 +40,24 @@ The `limit_by_label` block can be defined multiple times to define multiple labe * `key` - (Required) The key of the label. * `value` - (Required) The value of the label. +For example, to limit by the label `key` with values `value` and `value2`, plus the label `key1` with value `value`. +```hcl +limit_by_label { + key = "key" + value = "value" +} + +limit_by_label { + key = "key" + value = "value2" +} + +limit_by_label { + key = "key1" + value = "value" +} +``` + ## Import A Lacework Docker Hub container registry integration can be imported using a `INT_GUID`, e.g. diff --git a/website/docs/r/integration_docker_v2.html.markdown b/website/docs/r/integration_docker_v2.html.markdown index 4105c20c..69a85167 100644 --- a/website/docs/r/integration_docker_v2.html.markdown +++ b/website/docs/r/integration_docker_v2.html.markdown @@ -58,6 +58,24 @@ The `limit_by_label` block can be defined multiple times to define multiple labe * `key` - (Required) The key of the label. * `value` - (Required) The value of the label. +For example, to limit by the label `key` with values `value` and `value2`, plus the label `key1` with value `value`. +```hcl +limit_by_label { + key = "key" + value = "value" +} + +limit_by_label { + key = "key" + value = "value2" +} + +limit_by_label { + key = "key1" + value = "value" +} +``` + ## Import A Lacework Docker V2 container registry integration can be imported using a `INT_GUID`, e.g. diff --git a/website/docs/r/integration_ecr.html.markdown b/website/docs/r/integration_ecr.html.markdown index 4a93d136..bdc7408b 100644 --- a/website/docs/r/integration_ecr.html.markdown +++ b/website/docs/r/integration_ecr.html.markdown @@ -89,6 +89,24 @@ The `limit_by_label` block can be defined multiple times to define multiple labe * `key` - (Required) The key of the label. * `value` - (Required) The value of the label. +For example, to limit by the label `key` with values `value` and `value2`, plus the label `key1` with value `value`. +```hcl +limit_by_label { + key = "key" + value = "value" +} + +limit_by_label { + key = "key" + value = "value2" +} + +limit_by_label { + key = "key1" + value = "value" +} +``` + ### Credentials `credentials` supports the combination of the following arguments. diff --git a/website/docs/r/integration_gar.html.markdown b/website/docs/r/integration_gar.html.markdown index b1bbf065..daf4464c 100644 --- a/website/docs/r/integration_gar.html.markdown +++ b/website/docs/r/integration_gar.html.markdown @@ -43,28 +43,6 @@ module "gar" { To see the list of inputs, outputs and dependencies, visit the [Terraform registry page of this module](https://registry.terraform.io/modules/lacework/gar/gcp/latest). -## Example Loading Credentials from Local File - -Alternatively, this example shows how to load a [service account key created](https://cloud.google.com/iam/docs/creating-managing-service-account-keys#creating_service_account_keys) -using the Cloud Console or the `gcloud` command-line tool located on a local file on disk: - -```hcl -locals { - gar_credentials = jsondecode(file("/path/to/creds.json")) -} - -resource "lacework_integration_gar" "example" { - name = "GAR Example" - registry_domain = "us-west1-docker.pkg.dev" - credentials { - client_id = local.gar.client_id - client_email = local.gar.client_email - private_key_id = local.gar.private_key_id - private_key = local.gar.private_key - } -} -``` - ## Example Using Limits ```hcl @@ -117,6 +95,24 @@ The `limit_by_label` block can be defined multiple times to define multiple labe * `key` - (Required) The key of the label. * `value` - (Required) The value of the label. +For example, to limit by the label `key` with values `value` and `value2`, plus the label `key1` with value `value`. +```hcl +limit_by_label { + key = "key" + value = "value" +} + +limit_by_label { + key = "key" + value = "value2" +} + +limit_by_label { + key = "key1" + value = "value" +} +``` + ### Credentials `credentials` supports the following arguments: diff --git a/website/docs/r/integration_gcr.html.markdown b/website/docs/r/integration_gcr.html.markdown index b9b47469..728ff016 100644 --- a/website/docs/r/integration_gcr.html.markdown +++ b/website/docs/r/integration_gcr.html.markdown @@ -81,6 +81,24 @@ The `limit_by_label` block can be defined multiple times to define multiple labe * `key` - (Required) The key of the label. * `value` - (Required) The value of the label. +For example, to limit by the label `key` with values `value` and `value2`, plus the label `key1` with value `value`. +```hcl +limit_by_label { + key = "key" + value = "value" +} + +limit_by_label { + key = "key" + value = "value2" +} + +limit_by_label { + key = "key1" + value = "value" +} +``` + ### Credentials `credentials` supports the following arguments: diff --git a/website/docs/r/integration_ghcr.html.markdown b/website/docs/r/integration_ghcr.html.markdown index abf1b440..d8808791 100644 --- a/website/docs/r/integration_ghcr.html.markdown +++ b/website/docs/r/integration_ghcr.html.markdown @@ -43,6 +43,24 @@ The `limit_by_label` block can be defined multiple times to define multiple labe * `key` - (Required) The key of the label. * `value` - (Required) The value of the label. +For example, to limit by the label `key` with values `value` and `value2`, plus the label `key1` with value `value`. +```hcl +limit_by_label { + key = "key" + value = "value" +} + +limit_by_label { + key = "key" + value = "value2" +} + +limit_by_label { + key = "key1" + value = "value" +} +``` + ## Import A Lacework Github container registry integration can be imported using a `INT_GUID`, e.g.