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

Fleet Server package #544

Merged
merged 9 commits into from
Jan 20, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
- name: data_stream.type
type: constant_keyword
description: Datastream type.
- name: data_stream.dataset
type: constant_keyword
description: Datastream dataset.
- name: data_stream.namespace
type: constant_keyword
description: Datastream namespace.
- name: "@timestamp"
type: date
description: >
Event timestamp.

Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
- name: fleet_server
type: group
3 changes: 3 additions & 0 deletions packages/fleet_server/data_stream/fleet_server/manifest.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
title: Fleet Server
type: logs
release: experimental
1 change: 1 addition & 0 deletions packages/fleet_server/docs/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
# Fleet Server package
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
{
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@aleksmaus Very interesting that it just works with the dot prefix. It will make it fun to develop as some OS hide these files :-)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you mean windowz? :-)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OS X ...

"policy": {
"phases": {
"hot": {
"min_age": "0ms",
"actions": {
"rollover": {
"max_size": "300gb",
"max_age": "30d"
}
}
},
"delete": {
"min_age": "90d",
"actions": {
"delete": {
"delete_searchable_snapshot": true
}
}
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
{
"index_patterns": [
".fleet-actions-results"
],
"data_stream": {},
"template": {
"settings": {
"index.lifecycle.name": ".fleet-actions-results-ilm-policy"
},
"mappings": {
"dynamic": false,
"properties": {
"action_id": {
"type": "keyword"
},
"agent_id": {
"type": "keyword"
},
"data": {
"enabled": false,
"type": "object"
},
"error": {
"type": "keyword"
},
"@timestamp": {
"type": "date"
}
}
}
},
"composed_of": [],
"priority": 200,
"version": 1
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
{
"index_patterns": [
".fleet-actions"
],
"template": {
"settings": {},
"mappings": {
"dynamic": false,
"properties": {
"action_id": {
"type": "keyword"
},
"agents": {
"type": "keyword"
},
"data": {
"enabled": false,
"type": "object"
},
"expiration": {
"type": "date"
},
"input_id": {
"type": "keyword"
},
"@timestamp": {
"type": "date"
},
"type": {
"type": "keyword"
}
}
}
},
"composed_of": [],
"priority": 200,
"version": 1
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,94 @@
{
"index_patterns": [
".fleet-agents"
],
"template": {
"settings": {},
"mappings": {
"dynamic": false,
"properties": {
"access_api_key_id": {
"type": "keyword"
},
"action_seq_no": {
"type": "integer"
},
"active": {
"type": "boolean"
},
"agent": {
"properties": {
"id": {
"type": "keyword"
},
"version": {
"type": "keyword"
}
}
},
"default_api_key": {
"type": "keyword"
},
"default_api_key_id": {
"type": "keyword"
},
"enrolled_at": {
"type": "date"
},
"last_checkin": {
"type": "date"
},
"last_checkin_status": {
"type": "keyword"
},
"last_updated": {
"type": "date"
},
"local_metadata": {
"enabled": false,
"type": "object"
},
"packages": {
"type": "keyword"
},
"policy_coordinator_idx": {
"type": "integer"
},
"policy_id": {
"type": "keyword"
},
"policy_revision_idx": {
"type": "integer"
},
"shared_id": {
"type": "keyword"
},
"type": {
"type": "keyword"
},
"unenrolled_at": {
"type": "date"
},
"unenrollment_started_at": {
"type": "date"
},
"updated_at": {
"type": "date"
},
"upgrade_started_at": {
"type": "date"
},
"upgraded_at": {
"type": "date"
},
"user_provided_metadata": {
"enabled": false,
"type": "object"
}
}
}
},
"composed_of": [],
"priority": 200,
"version": 1
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
{
"index_patterns": [
".fleet-enrollment-api-keys"
],
"template": {
"settings": {},
"mappings": {
"dynamic": false,
"properties": {
"active": {
"type": "boolean"
},
"api_key": {
"type": "keyword"
},
"api_key_id": {
"type": "keyword"
},
"created_at": {
"type": "date"
},
"expire_at": {
"type": "date"
},
"name": {
"type": "keyword"
},
"policy_id": {
"type": "keyword"
},
"updated_at": {
"type": "date"
}
}
}
},
"composed_of": [],
"priority": 200,
"version": 1
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
{
"index_patterns": [
".fleet-policies-leader"
],
"template": {
"settings": {},
"mappings": {
"dynamic": false,
"properties": {
"server": {
"properties": {
"id": {
"type": "keyword"
},
"version": {
"type": "keyword"
}
}
},
"@timestamp": {
"type": "date"
}
}
}
},
"composed_of": [],
"priority": 200,
"version": 1
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
{
"index_patterns": [
".fleet-policies"
],
"template": {
"settings": {},
"mappings": {
"dynamic": false,
"properties": {
"coordinator_idx": {
"type": "integer"
},
"data": {
"enabled": false,
"type": "object"
},
"default_fleet_server": {
"type": "boolean"
},
"policy_id": {
"type": "keyword"
},
"revision_idx": {
"type": "integer"
},
"@timestamp": {
"type": "date"
}
}
}
},
"composed_of": [],
"priority": 200,
"version": 1
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
{
"index_patterns": [
".fleet-servers"
],
"template": {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wonder how restrictive we should be in these templates. Should we allow additional fields or not? If yes, keyword as default?

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For upgrades would that be good to add to all the templates? Just incase that Fleet Server itself is upgraded before the package?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Probably. In the ideal scenario the template would of course always be first and we could even use strict mappings, but not the case for now.

"settings": {},
"mappings": {
"dynamic": false,
"properties": {
"agent": {
"properties": {
"id": {
"type": "keyword"
},
"version": {
"type": "keyword"
}
}
},
"host": {
"properties": {
"architecture": {
"type": "keyword"
},
"id": {
"type": "keyword"
},
"ip": {
"type": "keyword"
},
"name": {
"type": "keyword"
}
}
},
"server": {
"properties": {
"id": {
"type": "keyword"
},
"version": {
"type": "keyword"
}
}
},
"@timestamp": {
"type": "date"
}
}
}
},
"composed_of": [],
"priority": 200,
"version": 1
}
Loading