Skip to content

Commit

Permalink
Fix kubernetes in-cluster configuration on IPv6 (elastic#8754)
Browse files Browse the repository at this point in the history
* Use patch to support ipv6 in k8s client
  • Loading branch information
jsoriano authored and exekias committed Oct 26, 2018
1 parent e3f74a6 commit eb0ee32
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 9 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ https://github.com/elastic/beats/compare/v6.4.0...master[Check the HEAD diff]
- Enforce that data used by k8s or docker doesn't use any reference. {pull}8240[8240]
- Switch to different UUID lib due to to non-random generated UUIDs. {pull}8485[8485]
- Fix race condition when publishing monitoring data. {pull}8646[8646]
- Fix in-cluster kubernetes configuration on IPv6. {pull}8754[8754]

*Auditbeat*

Expand Down
4 changes: 2 additions & 2 deletions NOTICE.txt
Original file line number Diff line number Diff line change
Expand Up @@ -611,8 +611,8 @@ subcomponents is subject to the terms and conditions of the
subcomponent's license, as noted in the LICENSE file.
--------------------------------------------------------------------
Dependency: github.com/ericchiang/k8s
Version: v1.0.0
Revision: 5912993f00cb7c971aaa54529a06bd3eecd6c3d4
Version: =v1.0.0/in-cluster-ipv6
Revision: 33b346590d1dd4eaac217471671f736bcdab492d
License type (autodetected): Apache-2.0
./vendor/github.com/ericchiang/k8s/LICENSE:
--------------------------------------------------------------------
Expand Down
2 changes: 1 addition & 1 deletion libbeat/common/kubernetes/util.go
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ func DiscoverKubernetesNode(host string, inCluster bool, client *k8s.Client) (no
pod := v1.Pod{}
err = client.Get(context.TODO(), ns, podName, &pod)
if err != nil {
logp.Err("kubernetes: Querying for pod failed with error: ", err.Error())
logp.Err("kubernetes: Querying for pod failed with error: %v", err.Error())
return defaultNode
}
logp.Info("kubernetes: Using node %s discovered by in cluster pod node query", pod.Spec.GetNodeName())
Expand Down
7 changes: 6 additions & 1 deletion vendor/github.com/ericchiang/k8s/client.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

11 changes: 6 additions & 5 deletions vendor/vendor.json
Original file line number Diff line number Diff line change
Expand Up @@ -1096,12 +1096,13 @@
"versionExact": "v0.9.0"
},
{
"checksumSHA1": "hTxFrbA619JCHysWjXHa9U6bfto=",
"checksumSHA1": "Klc34HULvwvY4cGA/D8HmqtXLqw=",
"origin": "github.com/jsoriano/k8s",
"path": "github.com/ericchiang/k8s",
"revision": "5912993f00cb7c971aaa54529a06bd3eecd6c3d4",
"revisionTime": "2018-01-20T20:28:12Z",
"version": "v1.0.0",
"versionExact": "v1.0.0"
"revision": "33b346590d1dd4eaac217471671f736bcdab492d",
"revisionTime": "2018-10-25T16:06:03Z",
"version": "=v1.0.0/in-cluster-ipv6",
"versionExact": "v1.0.0/in-cluster-ipv6"
},
{
"checksumSHA1": "uQuMoUlS7hAWsB+Mwr/1B7+35BU=",
Expand Down

0 comments on commit eb0ee32

Please sign in to comment.