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

Use 0.0.0.0 as otlp receiver default address #3126

Open
15 tasks
frzifus opened this issue Jul 14, 2024 · 8 comments
Open
15 tasks

Use 0.0.0.0 as otlp receiver default address #3126

frzifus opened this issue Jul 14, 2024 · 8 comments
Assignees
Labels
discuss-at-sig This issue or PR should be discussed at the next SIG meeting enhancement New feature or request

Comments

@frzifus
Copy link
Member

frzifus commented Jul 14, 2024

Component(s)

collector

Is your feature request related to a problem? Please describe.

The 0.104.0 collector release enables component.UseLocalHostAsDefaultHost by default. Since this would be a breaking change for the users, the operator in 0.104.0 reverts this change by updating fields like :4317 or empty fields to 0.0.0.0:4317.

Describe the solution you'd like

Maybe it does make sense to use the collector default localhost in sidecar scenarios and the $POD_IP for all the other modes.


Update

Add upgrade routine and default webhook entry for the following components(source open-telemetry/opentelemetry-collector#8510 (comment)):


Next:

  • Double check if we miss some components
  • Add upgrade routine to remove component.UseLocalHostAsDefaultHost feature-gate.
  • Remove component.UseLocalHostAsDefaultHost from defaulting webhook

Describe alternatives you've considered

Keep it like it is today or disable the component.UseLocalHostAsDefaultHost featuregate. (Which will be removed in the future).

Additional context

#3119 (comment)

@frzifus frzifus added enhancement New feature or request needs triage labels Jul 14, 2024
@frzifus
Copy link
Member Author

frzifus commented Jul 14, 2024

@pavolloffay
Copy link
Member

$POD_IP makes more sense than 0:0:0:0 but I don't know if there is a big difference for deployment/SS pods, but maybe it matters more in e.g. daemonset .

@matthagenbuch
Copy link
Contributor

For services running in kubernetes, the norm is to bind to the 0 address. Binding to pod_ip may be slightly more secure since it is a smaller surface area, but it could result in unexpected behavior, such as when using kubectl port-forward. As a user I would prefer binding to the 0 address by default for convention / convenience.

@frzifus frzifus changed the title Use $POD_IP as otlp receiver default address Use 0.0.0.0 as otlp receiver default address Jul 16, 2024
@frzifus
Copy link
Member Author

frzifus commented Jul 17, 2024

Something you want to work on @led0nk? :)

@led0nk
Copy link

led0nk commented Jul 17, 2024

Yes, please

@frzifus
Copy link
Member Author

frzifus commented Jul 18, 2024

Does it make sense to hide this behaviour behind a feature gate on the operator that we enable once we disable the component.UseLocalHostAsDefaultHost feature gate on the collector?

cc @pavolloffay @swiatekm @jaronoff97

@jaronoff97
Copy link
Contributor

would this featuregate be enabled by default and eventually removed?

@frzifus
Copy link
Member Author

frzifus commented Jul 18, 2024

It should be enabled by default once component.UseLocalHostAsDefaultHost is removed on the collector side.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
discuss-at-sig This issue or PR should be discussed at the next SIG meeting enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

5 participants