provider "aws" {
}
module "coralogix-shipper-s3" {
source = "coralogix/aws/coralogix//modules/s3"
coralogix_region = "Europe"
private_key = "XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXX"
application_name = "s3"
subsystem_name = "logs"
s3_bucket_name = "test-bucket-name"
integration_type = "s3"
}
now execute:
$ terraform init
$ terraform plan
$ terraform apply
To run this example you need to save this code in Terraform file, and change the values according to our settings.
provider "aws" {
}
module "cloudwatch_logs" {
source = "coralogix/aws/coralogix//modules/cloudwatch-logs"
coralogix_region = "Europe"
private_key = "XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXX"
application_name = "cloudwatch"
subsystem_name = "logs"
log_groups = ["test-log-group"]
}
now execute:
$ terraform init
$ terraform plan
$ terraform apply
Run terraform destroy
when you don't need these resources.
Provision an ECS Service that run the OTEL Collector Agent as a Daemon container on each EC2 container instance. For parameter details, see ECS-EC2 module README
module "ecs-ec2" {
source = "../../modules/ecs-ec2"
ecs_cluster_name = "ecs-cluster-name"
image_version = "latest"
memory = numeric MiB
coralogix_region = ["Europe"|"Europe2"|"India"|"Singapore"|"US"|"US2"]
custom_domain = "[optional] custom Coralogix domain"
default_application_name = "Coralogix Application Name"
default_subsystem_name = "Coralogix Subsystem Name"
api_key = var.api_key
otel_config_file = "[optional] file path to custom OTEL collector config file"
metrics = [true|false]
tags = {} # optional
task_definition_arn = "[optional] arn"
}
now execute:
$ terraform init
$ terraform plan
$ terraform apply
Run terraform destroy
when you don't need these resources.
provider "aws" {
}
module "kinesis" {
source = "coralogix/aws/coralogix//modules/kinesis"
coralogix_region = "Europe"
private_key = "XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXX"
application_name = "kinesis"
subsystem_name = "logs"
kinesis_stream_name = "<your kinesis stream name>"
}
now execute:
$ terraform init
$ terraform plan
$ terraform apply
Run terraform destroy
when you don't need these resources.
provider "aws" {
}
module "cloudwatch_firehose_logs_coralogix" {
source = "coralogix/aws/coralogix//modules/firehose-logs"
coralogix_region = "Europe"
private_key = "XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXX"
application_name = "firehose-logs"
subsystem_name = "logs"
firehose_stream = "<your kinesis stream name>"
#logs:
integration_type_logs = "CloudWatch_JSON"
}
now execute:
$ terraform init
$ terraform plan
$ terraform apply
Then create subscription filters in your CloudWatch log groups to send logs to the firehose logs delivery stream.
provider "aws" {
}
module "cloudwatch_firehose_metrics_coralogix" {
source = "coralogix/aws/coralogix//modules/firehose-metrics"
coralogix_region = "Europe"
private_key = "XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXX"
application_name = "firehose-metrics"
subsystem_name = "metrics"
firehose_stream = "<your kinesis stream name>"
#metrics:
enable_cloudwatch_metricstream = true
}
now execute:
$ terraform init
$ terraform plan
$ terraform apply
Metrics collected by the created CloudWatch Metric Stream will be sent to the firehose metrics delivery stream.
provider "aws" {
}
module "coralogix-resource-metadata" {
source = "coralogix/aws/coralogix//modules/resource-metadata"
coralogix_region = "Europe"
private_key = "XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXX"
}
now execute:
$ terraform init
$ terraform plan
$ terraform apply
- cloudwatch-logs - Send logs from
CloudWatch
. - s3 - Send logs from
S3
bucket. - ecs-ec2 - Send logs, metrics, traces from OTEL Collector on ECS EC2 container instances.
- eventbridge - Send logs from
eventbrdge
. - firehose-logs - Send logs streams with
firehose
. - firehose-metrics - Send metric streams with
firehose
. - kinesis - Send logs from
kinesis data stream
with lambda. - resource-metadata - Send metadata from your AWS account to coralogix.
- s3-archive - Create s3 archives for coralogix logs and metrics.
Module is maintained by Coralogix.
Apache 2 Licensed. See LICENSE for full details.