2016-12-12 16:28:26 +01:00
|
|
|
---
|
|
|
|
layout: "icinga2"
|
|
|
|
page_title: "Icinga2: hostgroup"
|
|
|
|
sidebar_current: "docs-icinga2-resource-hostgroup"
|
|
|
|
description: |-
|
|
|
|
Configures a hostgroup resource. This allows hostgroup to be configured, updated and deleted.
|
|
|
|
---
|
|
|
|
|
|
|
|
# icinga2\_hostgroup
|
|
|
|
|
|
|
|
Configures an Icinga2 hostgroup resource. This allows hostgroup to be configured, updated,
|
2017-02-18 23:48:50 +01:00
|
|
|
and deleted.
|
2016-12-12 16:28:26 +01:00
|
|
|
|
|
|
|
## Example Usage
|
|
|
|
|
|
|
|
```
|
|
|
|
# Configure a new hostgroup to be monitored by an Icinga2 Server
|
|
|
|
provider "icinga2" {
|
2017-02-18 23:48:50 +01:00
|
|
|
api_url = "https://192.168.33.5:5665/v1"
|
2016-12-12 16:28:26 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
resource "icinga2_hostgroup" "my-hostgroup" {
|
2017-02-18 23:48:50 +01:00
|
|
|
name = "terraform-hostgroup-1"
|
2016-12-12 16:28:26 +01:00
|
|
|
display_name = "Terraform Test HostGroup"
|
|
|
|
}
|
|
|
|
```
|
|
|
|
|
|
|
|
## Argument Reference
|
|
|
|
|
|
|
|
The following arguments are supported:
|
|
|
|
|
|
|
|
* `name` - (Required) The name of the hostgroup.
|
|
|
|
* `display_name` - (Required) The name of the hostgroup to display in the Icinga2 interface.
|
|
|
|
|