Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support input groups #137

Merged
merged 17 commits into from
Mar 2, 2021
2 changes: 1 addition & 1 deletion code/go/internal/spec/statik.go

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions code/go/pkg/validator/validator_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ func TestValidateFile(t *testing.T) {
},
},
"input_template": {},
"input_groups": {},
}

for pkgName, test := range tests {
Expand Down
1 change: 1 addition & 0 deletions test/packages/input_groups/_dev/build/docs/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
README for integration
1 change: 1 addition & 0 deletions test/packages/input_groups/_dev/build/docs/dynamodb.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
DynamoDB README template file
1 change: 1 addition & 0 deletions test/packages/input_groups/_dev/build/docs/ec2.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
EC2 README template file
5 changes: 5 additions & 0 deletions test/packages/input_groups/changelog.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
- version: 1.0.0
changes:
- description: initial release
type: enhancement
link: https://github.com/elastic/package-spec/pull/0
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
# Handlebars template for agent
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
- name: aws.dynamodb
type: group
36 changes: 36 additions & 0 deletions test/packages/input_groups/data_stream/dynamodb/manifest.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
title: AWS DynamoDB metrics
release: beta
type: metrics
streams:
- input: aws/metrics
vars:
- name: period
type: text
title: Period
multi: false
required: true
show_user: true
default: 5m
- name: regions
type: text
title: Regions
multi: true
required: false
show_user: true
- name: latency
type: text
title: Latency
multi: false
required: false
show_user: false
- name: tags_filter
type: yaml
title: Tags Filter
multi: false
required: false
show_user: false
default: |
# - key: "created-by"
# value: "foo"
title: AWS DynamoDB metrics
description: Collect AWS DynamoDB metrics
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
# Handlebars template for agent
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
---
description: "Pipeline for EC2 logs in CloudWatch"
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
- name: aws.ec2
type: group
24 changes: 24 additions & 0 deletions test/packages/input_groups/data_stream/ec2_logs/manifest.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
title: AWS EC2 logs
release: beta
type: logs
streams:
- input: s3
template_path: s3.yml.hbs
title: AWS EC2 logs
description: Collect AWS EC2 logs using s3 input
vars:
- name: queue_url
type: text
title: Queue URL
multi: false
required: true
show_user: true
description: URL of the AWS SQS queue that messages will be received from.
- name: fips_enabled
type: bool
title: Enable S3 FIPS
default: false
multi: false
required: false
show_user: false
description: Enabling this option changes the service name from `s3` to `s3-fips` for connecting to the correct service endpoint.
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
# Handlebars template for agent
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
- name: aws.ec2
type: group
36 changes: 36 additions & 0 deletions test/packages/input_groups/data_stream/ec2_metrics/manifest.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
title: AWS EC2 metrics
release: beta
type: metrics
streams:
- input: aws/metrics
vars:
- name: period
type: text
title: Period
multi: false
required: true
show_user: true
default: 5m
- name: regions
type: text
title: Regions
multi: true
required: false
show_user: true
- name: latency
type: text
title: Latency
multi: false
required: false
show_user: false
- name: tags_filter
type: yaml
title: Tags Filter
multi: false
required: false
show_user: false
default: |
# - key: "created-by"
# value: "foo"
title: AWS EC2 metrics
description: Collect AWS EC2 metrics
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
# Stream Handlebars template
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
# TCP Handlebars template
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
# UDP Handlebars template
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
---
description: Pipeline for Barracuda Spam Firewall
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
- name: rsa
type: group
95 changes: 95 additions & 0 deletions test/packages/input_groups/data_stream/spamfirewall/manifest.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,95 @@
title: Barracuda Spam Firewall logs
release: experimental
type: logs
streams:
- input: udp
title: Barracuda Spam Firewall logs
description: Collect Barracuda Spam Firewall logs
template_path: udp.yml.hbs
vars:
- name: udp_host
type: text
title: UDP host to listen on
multi: false
required: true
show_user: true
default: localhost
- name: udp_port
type: integer
title: UDP port to listen on
multi: false
required: true
show_user: true
default: 9540
- name: tz_offset
type: text
title: Timezone offset (+HH:mm format)
required: false
show_user: true
default: "local"
- name: rsa_fields
type: bool
title: Add non-ECS fields
required: false
show_user: true
default: true
- name: keep_raw_fields
type: bool
title: Keep raw parser fields
required: false
show_user: false
default: false
- input: tcp
title: Barracuda Spam Firewall logs
description: Collect Barracuda Spam Firewall logs
template_path: tcp.yml.hbs
vars:
- name: tcp_host
type: text
title: TCP host to listen on
multi: false
required: true
show_user: true
default: localhost
- name: tcp_port
type: integer
title: TCP port to listen on
multi: false
required: true
show_user: true
default: 9540
- name: tz_offset
type: text
title: Timezone offset (+HH:mm format)
required: false
show_user: true
default: "local"
- name: keep_raw_fields
type: bool
title: Keep raw parser fields
required: false
show_user: false
default: false
- input: logfile
enabled: false
title: Barracuda Spam Firewall logs
description: Collect Barracuda Spam Firewall logs from file
vars:
- name: rsa_fields
type: bool
title: Add non-ECS fields
required: false
show_user: true
default: true
- name: keep_raw_fields
type: bool
title: Keep raw parser fields
required: false
show_user: false
default: false
- name: debug
type: bool
title: Enable debug logging
required: false
show_user: false
default: false
1 change: 1 addition & 0 deletions test/packages/input_groups/docs/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
README for integration
1 change: 1 addition & 0 deletions test/packages/input_groups/docs/dynamodb.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
DynamoDB README file
1 change: 1 addition & 0 deletions test/packages/input_groups/docs/ec2.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
EC2 README file
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions test/packages/input_groups/img/aws-dynamodb.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions test/packages/input_groups/img/aws-ec2.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions test/packages/input_groups/img/aws-logo.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading