Sha256: b2bc429c5c42262ede7c90e47a5edca3b5c6601361628852bf462ca92eae33e9

Contents?: true

Size: 628 Bytes

Versions: 15

Compression:

Stored size: 628 Bytes

Contents

<% module_namespacing do -%>
class <%= class_name %>Job < ApplicationJob
  rule_event(
    description: "Checks for security group changes",
    detail_type: ["AWS API Call via CloudTrail"],
    detail: {
      event_source: ["ec2.amazonaws.com"],
      event_name: [
        "AuthorizeSecurityGroupIngress",
        "AuthorizeSecurityGroupEgress",
        "RevokeSecurityGroupIngress",
        "RevokeSecurityGroupEgress",
        "CreateSecurityGroup",
        "DeleteSecurityGroup"
      ]
    }
  )
  def <%= options[:name] %>
    puts "event: #{JSON.dump(event)}" # event is available
    # your logic
  end
end
<% end -%>

Version data entries

15 entries across 15 versions & 1 rubygems

Version Path
jets-5.0.13 lib/jets/generators/job/templates/event_types/rule.rb.tt
jets-5.0.12 lib/jets/generators/job/templates/event_types/rule.rb.tt
jets-5.0.11 lib/jets/generators/job/templates/event_types/rule.rb.tt
jets-5.0.10 lib/jets/generators/job/templates/event_types/rule.rb.tt
jets-5.0.9 lib/jets/generators/job/templates/event_types/rule.rb.tt
jets-5.0.8 lib/jets/generators/job/templates/event_types/rule.rb.tt
jets-5.0.7 lib/jets/generators/job/templates/event_types/rule.rb.tt
jets-5.0.6 lib/jets/generators/job/templates/event_types/rule.rb.tt
jets-5.0.5 lib/jets/generators/job/templates/event_types/rule.rb.tt
jets-5.0.4 lib/jets/generators/job/templates/event_types/rule.rb.tt
jets-5.0.3 lib/jets/generators/job/templates/event_types/rule.rb.tt
jets-5.0.2 lib/jets/generators/job/templates/event_types/rule.rb.tt
jets-5.0.1 lib/jets/generators/job/templates/event_types/rule.rb.tt
jets-5.0.0 lib/jets/generators/job/templates/event_types/rule.rb.tt
jets-5.0.0.beta1 lib/jets/generators/job/templates/event_types/rule.rb.tt