Selected hostnames
akamai_appsec_selected_hostnames
Deprecated
Hello. Just a note to let you know this data source is deprecated with a scheduled end-of-life in v7.0.0 of our provider.
We've made this change because the
APPEND
mode of the underlying API doesn't work well with Terraform's declarative nature and using it causes security configuration drift.To get information about your selected hostnames, use the
akamai_appsec_configuration
data source instead.
Returns a list of the hostnames currently protected by the specified security configuration.
Scopes: Security configuration
Example
terraform {
required_providers {
akamai = {
source = "akamai/akamai"
}
}
}
provider "akamai" {
edgerc = "~/.edgerc"
}
data "akamai_appsec_configuration" "configuration" {
name = "Documentation"
}
data "akamai_appsec_selected_hostnames" "selected_hostnames" {
config_id = data.akamai_appsec_configuration.configuration.config_id
}
output "selected_hostnames" {
value = data.akamai_appsec_selected_hostnames.selected_hostnames.hostnames
}
output "selected_hostnames_json" {
value = data.akamai_appsec_selected_hostnames.selected_hostnames.hostnames_json
}
output "selected_hostnames_output_text" {
value = data.akamai_appsec_selected_hostnames.selected_hostnames.output_text
}
Argument reference
This data source supports the following arguments:
config_id
(Required). Unique identifier of the security configuration associated with the protected hosts.
Output options
The following options can be used to determine the information returned, and how that returned information is formatted:
hostnames
. List of selected hostnames.hostnames_json
. JSON-formatted list of selected hostnames.output_text
. Tabular report of the selected hostnames.
Updated about 2 months ago