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

[receiver/dockerstatsreceiver] Does not support setting TLS settings #33557

Open
moserke opened this issue Jun 13, 2024 · 4 comments
Open

[receiver/dockerstatsreceiver] Does not support setting TLS settings #33557

moserke opened this issue Jun 13, 2024 · 4 comments
Labels

Comments

@moserke
Copy link

moserke commented Jun 13, 2024

Component(s)

receiver/dockerstats

What happened?

Description

In trying to set up a receiver for a TLS protected containerd daemon over a docker socket, can not set TLS settings and therefore get malformed http responses. Because you can't specify the scheme in the unix socket name the net/http layer assumes http protocol.

You can see this in the error output of

"http://containerd.sock/v1.25/containers/json?filters=%7B%22status%22%3A%7B%22running%22%3Atrue%7D%7D": net/http: HTTP/1.x transport connection broken: malformed HTTP response "\x00\x00\x06\x04\x00\x00\x00\x00\x00\x00\x05\x00\x00@\x00".
* Are you trying to connect to a TLS-enabled daemon without TLS?

Can you actually do this or is this something that is not supported today?

Collector version

0.102.1

Environment information

Environment

OS: (e.g., "Ubuntu 20.04")
Compiler(if manually compiled): (e.g., "go 14.2")

OpenTelemetry Collector configuration

docker_stats:
  endpoint: unix://containerd.sock

Log output

No response

Additional context

No response

@moserke moserke added bug Something isn't working needs triage New item requiring triage labels Jun 13, 2024
Copy link
Contributor

Pinging code owners:

See Adding Labels via Comments if you do not have permissions to add labels yourself.

Copy link
Contributor

This issue has been inactive for 60 days. It will be closed in 60 days if there is no activity. To ping code owners by adding a component label, see Adding Labels via Comments, or if you are unsure of which component this issue relates to, please ping @open-telemetry/collector-contrib-triagers. If this issue is still relevant, please ping the code owners or leave a comment explaining why it is still relevant. Otherwise, please close it.

Pinging code owners:

See Adding Labels via Comments if you do not have permissions to add labels yourself.

@jamesmoessis
Copy link
Contributor

@moserke I would be happy to review if you raise a PR for this. I am assuming this would only apply if the daemon is done over TCP, not unix socket?

Copy link
Contributor

github-actions bot commented Dec 2, 2024

This issue has been inactive for 60 days. It will be closed in 60 days if there is no activity. To ping code owners by adding a component label, see Adding Labels via Comments, or if you are unsure of which component this issue relates to, please ping @open-telemetry/collector-contrib-triagers. If this issue is still relevant, please ping the code owners or leave a comment explaining why it is still relevant. Otherwise, please close it.

Pinging code owners:

See Adding Labels via Comments if you do not have permissions to add labels yourself.

@github-actions github-actions bot added the Stale label Dec 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants