Skip to content

Commit

Permalink
Remove add_docker_metadata from Functionbeat configuration (elastic#1…
Browse files Browse the repository at this point in the history
…4424)

The PR elastic#13374 adds `add_docker_metadata` for all Beats. However, this results in the following error in Functionbeat when deployed to AWS:
```
Exiting: error initializing processors: Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?
```

Thus, the function fails to start and process messages.

This PR removes the processor from the configuration of Functionbeat. So the function is able to start with the default processor configuration.
  • Loading branch information
kvch authored Nov 12, 2019
1 parent aaca48b commit d9a4c9c
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 6 deletions.
1 change: 1 addition & 0 deletions dev-tools/mage/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,7 @@ func Config(types ConfigFileType, args ConfigFileParams, targetDir string) error
"ExcludeLogstash": false,
"ExcludeRedis": false,
"UseObserverProcessor": false,
"UseDockerMetadataProcessor": true,
"UseKubernetesMetadataProcessor": false,
"ExcludeDashboards": false,
}
Expand Down
3 changes: 2 additions & 1 deletion libbeat/_meta/config.yml.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,8 @@ output.elasticsearch:
processors:
- add_host_metadata: ~
- add_cloud_metadata: ~
- add_docker_metadata: ~
{{- if .UseDockerMetadataProcessor }}
- add_docker_metadata: ~{{ end }}

{{- if .UseKubernetesMetadataProcessor }}
- add_kubernetes_metadata: ~
Expand Down
1 change: 0 additions & 1 deletion x-pack/functionbeat/functionbeat.yml
Original file line number Diff line number Diff line change
Expand Up @@ -347,7 +347,6 @@ output.elasticsearch:
processors:
- add_host_metadata: ~
- add_cloud_metadata: ~
- add_docker_metadata: ~

#================================ Logging =====================================

Expand Down
9 changes: 5 additions & 4 deletions x-pack/functionbeat/scripts/mage/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,11 @@ func XPackConfigFileParams() devtools.ConfigFileParams {
devtools.LibbeatDir("_meta/config.reference.yml.tmpl"),
},
ExtraVars: map[string]interface{}{
"ExcludeConsole": true,
"ExcludeFileOutput": true,
"ExcludeKafka": true,
"ExcludeRedis": true,
"ExcludeConsole": true,
"ExcludeFileOutput": true,
"ExcludeKafka": true,
"ExcludeRedis": true,
"UseDockerMetadataProcessor": false,
},
}
}

0 comments on commit d9a4c9c

Please sign in to comment.