Provides details about a specific redshift cluster.
data "aws_redshift_cluster" "example" {
cluster_identifier = "example-cluster"
}
resource "aws_kinesis_firehose_delivery_stream" "example_stream" {
name = "terraform-kinesis-firehose-example-stream"
destination = "redshift"
redshift_configuration {
role_arn = aws_iam_role.firehose_role.arn
cluster_jdbcurl = "jdbc:redshift://${data.aws_redshift_cluster.example.endpoint}/${data.aws_redshift_cluster.example.database_name}"
username = "exampleuser"
password = "Exampl3Pass"
data_table_name = "example-table"
copy_options = "delimiter '|'" # the default delimiter
data_table_columns = "example-col"
s3_configuration {
role_arn = aws_iam_role.firehose_role.arn
bucket_arn = aws_s3_bucket.bucket.arn
buffer_size = 10
buffer_interval = 400
compression_format = "GZIP"
}
}
}
This data source supports the following arguments:
cluster_identifier
- (Required) Cluster identifierThis data source exports the following attributes in addition to the arguments above:
arn
- ARN of cluster.allow_version_upgrade
- Whether major version upgrades can be applied during maintenance periodautomated_snapshot_retention_period
- The backup retention periodaqua_configuration_status
- The value represents how the cluster is configured to use AQUA.availability_zone
- Availability zone of the clusteravailability_zone_relocation_enabled
- Indicates whether the cluster is able to be relocated to another availability zone.bucket_name
- Name of the S3 bucket where the log files are to be storedcluster_identifier
- Cluster identifiercluster_nodes
- Nodes in the cluster. Cluster node blocks are documented belowcluster_parameter_group_name
- The name of the parameter group to be associated with this clustercluster_public_key
- Public key for the clustercluster_revision_number
- The cluster revision numbercluster_subnet_group_name
- The name of a cluster subnet group to be associated with this clustercluster_type
- Cluster typecluster_namespace_arn
- The namespace Amazon Resource Name (ARN) of the clusterdatabase_name
- Name of the default database in the clusterdefault_iam_role_arn
- The ARN for the IAM role that was set as default for the cluster when the cluster was created.elastic_ip
- Elastic IP of the clusterenable_logging
- Whether cluster logging is enabledencrypted
- Whether the cluster data is encryptedendpoint
- Cluster endpointenhanced_vpc_routing
- Whether enhanced VPC routing is enablediam_roles
- IAM roles associated to the clusterkms_key_id
- KMS encryption key associated to the clustermaster_username
- Username for the master DB usermulti_az
- If the cluster is a Multi-AZ deploymentnode_type
- Cluster node typenumber_of_nodes
- Number of nodes in the clustermaintenance_track_name
- The name of the maintenance track for the restored cluster.manual_snapshot_retention_period
- (Optional) The default number of days to retain a manual snapshot.port
- Port the cluster responds onpreferred_maintenance_window
- The maintenance windowpublicly_accessible
- Whether the cluster is publicly accessibles3_key_prefix
- Folder inside the S3 bucket where the log files are storedlog_destination_type
- The log destination type.log_exports
- Collection of exported log types. Log types include the connection log, user log and user activity log.tags
- Tags associated to the clustervpc_id
- VPC Id associated with the clustervpc_security_group_ids
- The VPC security group Ids associated with the clusterCluster nodes (for cluster_nodes
) support the following attributes:
node_role
- Whether the node is a leader node or a compute nodeprivate_ip_address
- Private IP address of a node within a clusterpublic_ip_address
- Public IP address of a node within a cluster