-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
⭐️ new resource mondoo_integration_gitlab (#167)
Signed-off-by: Matthias Theuermann <[email protected]>
- Loading branch information
1 parent
708004c
commit 8272dc9
Showing
6 changed files
with
459 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,82 @@ | ||
--- | ||
# generated by https://github.com/hashicorp/terraform-plugin-docs | ||
page_title: "mondoo_integration_gitlab Resource - terraform-provider-mondoo" | ||
subcategory: "" | ||
description: |- | ||
Continuously scan GitLab for misconfigurations. | ||
--- | ||
|
||
# mondoo_integration_gitlab (Resource) | ||
|
||
Continuously scan GitLab for misconfigurations. | ||
|
||
## Example Usage | ||
|
||
```terraform | ||
variable "gitlab_token" { | ||
description = "The GitLab Token" | ||
type = string | ||
sensitive = true | ||
} | ||
provider "mondoo" { | ||
space = "hungry-poet-123456" | ||
} | ||
# Setup the GitLab integration | ||
resource "mondoo_integration_gitlab" "gitlab_integration" { | ||
name = "GitLab Integration" | ||
# base_url = "https://my-self-hosted-gitlab.com" | ||
# group = "my-group" | ||
# configure discovery options | ||
discovery = { | ||
groups = true | ||
projects = true | ||
terraform = true | ||
k8s_manifests = true | ||
} | ||
credentials = { | ||
token = var.gitlab_token | ||
} | ||
} | ||
``` | ||
|
||
<!-- schema generated by tfplugindocs --> | ||
## Schema | ||
|
||
### Required | ||
|
||
- `credentials` (Attributes) (see [below for nested schema](#nestedatt--credentials)) | ||
- `name` (String) Name of the integration. | ||
|
||
### Optional | ||
|
||
- `base_url` (String) Base URL of the GitLab instance (only set this if your instance is self-hosted). | ||
- `discovery` (Attributes) (see [below for nested schema](#nestedatt--discovery)) | ||
- `group` (String) Group to assign the integration to (by default all groups are discovered). | ||
- `space_id` (String) Mondoo Space Identifier. If it is not provided, the provider space is used. | ||
|
||
### Read-Only | ||
|
||
- `mrn` (String) Integration identifier | ||
|
||
<a id="nestedatt--credentials"></a> | ||
### Nested Schema for `credentials` | ||
|
||
Required: | ||
|
||
- `token` (String, Sensitive) Token for GitLab integration. | ||
|
||
|
||
<a id="nestedatt--discovery"></a> | ||
### Nested Schema for `discovery` | ||
|
||
Optional: | ||
|
||
- `groups` (Boolean) Enable discovery of GitLab groups. | ||
- `k8s_manifests` (Boolean) Enable discovery of Kubernetes manifests. | ||
- `projects` (Boolean) Enable discovery of GitLab projects. | ||
- `terraform` (Boolean) Enable discovery of Terraform configurations. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
terraform { | ||
required_providers { | ||
mondoo = { | ||
source = "mondoohq/mondoo" | ||
version = ">= 0.19" | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
variable "gitlab_token" { | ||
description = "The GitLab Token" | ||
type = string | ||
sensitive = true | ||
} | ||
|
||
provider "mondoo" { | ||
space = "hungry-poet-123456" | ||
} | ||
|
||
# Setup the GitLab integration | ||
resource "mondoo_integration_gitlab" "gitlab_integration" { | ||
name = "GitLab Integration" | ||
|
||
# base_url = "https://my-self-hosted-gitlab.com" | ||
# group = "my-group" | ||
|
||
# configure discovery options | ||
discovery = { | ||
groups = true | ||
projects = true | ||
terraform = true | ||
k8s_manifests = true | ||
} | ||
|
||
credentials = { | ||
token = var.gitlab_token | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.