Skip to content
Discussion options

You must be logged in to vote

I managed to do it with the following configuration:

api:
  enabled: true
  address: "0.0.0.0:8686"

log_schema:
  timestamp_key: "eventTime"

sources:
  vector_metrics:
    type: "internal_metrics"

  cloudtrailsource:
    type: http_server
    address: 0.0.0.0:8090
    method: POST
    path: /cloudtrail
    strict_path: true
    encoding: text
    response_code: 200

transforms:
  transformcloudtrail:
    type: remap
    inputs:
      - cloudtrailsource
    source: |
      parsed = parse_json!(.message)
      . = unnest!(parsed.Records)
      . = map_values(.) -> |value| {
        event = del(value.Records)
        value |= object!(event)
      }
  mutate:
    type: remap
    inputs:
  …

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by omers
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants