Giter Site home page Giter Site logo

terraform-aws-eventbridge's Introduction

terraform-aws-eventbridge

Usage

module "schedule" {
  source = "git::ssh://[email protected]/oozou/terraform-aws-eventbridge.git?ref=<version>"

  prefix      = "oozou"
  environment = "devops"
  name        = "subulu"

  schedule_expression         = "cron(0/5 * ? * MON-FRI *)"
  cloudwatch_event_target_arn = "arn:aws:states:us-east-2:556611339911:stateMachine:menual-deo-steps-function"
  input = jsonencode(
    {
      cluster_name   = "oozou-devops-eks-cluster"
      nodegroup_name = "oozou-devops-eks-sabarakata-nodegroup"
      min            = 0,
      max            = 1,
      desired        = 0
      taint_key      = "dedicated"
      taint_value    = "stop"
    }
  )

  role_arn = "arn:aws:iam::556611339911:role/service-role/StepFunctions-menual-deo-steps-function-role-617c576c"

  tags = {
    "Workspace" = "xxx-yyy-zzz"
  }
}

Requirements

Name Version
terraform >= 1.0.0
aws >= 4.00

Providers

Name Version
aws 4.23.0

Modules

No modules.

Resources

Name Type
aws_cloudwatch_event_bus.this resource
aws_cloudwatch_event_rule.this resource
aws_cloudwatch_event_target.this resource
aws_cloudwatch_event_bus.this data source

Inputs

Name Description Type Default Required
bus_name A unique name for your EventBridge Bus string "default" no
cloudwatch_event_rule_is_enabled Whether the rule should be enabled. bool true no
cloudwatch_event_target A map of objects with EventBridge Target definitions. any {} no
cloudwatch_event_target_arn The Amazon Resource Name (ARN) associated of the target. string n/a yes
cloudwatch_event_target_id The unique target assignment ID. If missing, will generate a random, unique id. string null no
dead_letter_config_arn (Optional) Parameters used when you are providing a dead letter config. Documented below. A maximum of 1 are allowed. string null no
environment Environment Variable used as a prefix string n/a yes
event_description The description of the rule. string "" no
event_pattern (Optional) The event pattern described a JSON object. At least one of schedule_expression or event_pattern is required. string null no
input Valid JSON text passed to the target. Conflicts with input_path and input_transformer. string null no
input_path (Optional) The value of the JSONPath that is used for extracting part of the matched event when passing it to the target. Conflicts with input and input_transformer. string null no
input_transformer Parameters used when you are providing a custom input to a target based on certain event data
example:
input_transformer = {
input_paths = {
severity="$.detail.severity",
Finding_Type="$.detail.type"
}
input_template = ""You have a severity GuardDuty finding type <Finding_Type>""
}
object({
input_paths = map(any)
input_template = string
})
null no
name Name of the ECS cluster to create string n/a yes
prefix The prefix name of customer to be displayed in AWS console and resource string n/a yes
retry_policy (Optional) Parameters used when you are providing retry policies. Documented below. A maximum of 1 are allowed.
object({
maximum_retry_attempts = number
maximum_event_age_in_seconds = number
})
{
"maximum_event_age_in_seconds": 3600,
"maximum_retry_attempts": 100
}
no
role_arn (Optional) The Amazon Resource Name (ARN) of the IAM role to be used for this target when the rule is triggered. Required if ecs_target is used or target in arn is EC2 instance, Kinesis data stream, Step Functions state machine, or Event Bus in different account or region. string "" no
run_command_targets (Optional) Parameters used when you are using the rule to invoke Amazon EC2 Run Command. Documented below. A maximum of 5 are allowed.
list(object({
key = string
values = list(string)
}))
[] no
schedule_expression (Optional) The scheduling expression. For example, cron(0 20 * * ? *) or rate(5 minutes) string null no
tags Custom tags which can be passed on to the AWS resources. They should be key value pairs having distinct keys map(any) {} no

Outputs

Name Description
aws_cloudwatch_event_rule_arn The Amazon Resource Name (ARN) of the rule.
aws_cloudwatch_event_rule_id The name of the rule

terraform-aws-eventbridge's People

Contributors

bemillenium avatar lycbrian avatar xshot9011 avatar

Stargazers

 avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.