Closed OrangeTimes closed 4 years ago
It's docker_engine not docker-engine.
- name: docker-pipe
hostPath:
path: '\\.\pipe\docker_engine'
type: null
Also you'll want
env:
- name: NODE_NAME
valueFrom:
fieldRef:
fieldPath: spec.nodeName
Thanks
Kubernetes version: v.1.15.6 Docker Engine on kubernetes node: 19.3.4 Server: Windows Server 2019 Standard 10.0.17763.1217
Steps to reproduce:
Actual result: The same image works smoothly if run using docker on kubernetes node but Kuberentes pods crashes. If you analyze logs you will see error dring startup of cStatsExporter: Starting... Configuration read. Scrap time = 15 seconds. panic: error during connect: This error may indicate that the docker daemon is not running.: Get "http://%2F%2F.%2Fpipe%2Fdocker_engine/v1.24/containers/json?limit=0": open //./pipe/docker_engine: The system cannot find the file specified.
goroutine 1 [running]: main.GatherMetrics() /main.go:285 +0x221d main.main() /main.go:121 +0x129