Skip to content

Conversation

anilvpatel
Copy link
Contributor

Description

When no explicit flags are provided, Envoy should default to 127.0.0.1 in IPv4-only environments and ::1 in IPv6/Dual Stack environment determine based on the local agent bind_addr.

PR Checklist

  • [ x] updated test coverage
  • external facing docs updated
  • appropriate backport labels added
  • [ x] not a security concern

nitin-sachdev-29 and others added 8 commits September 10, 2025 14:27
- Upgraded `github.com/miekg/dns` dependency to v1.1.68.
- Included `BindAddr` in agent endpoint and enabled binding logic in IP offset calculations.
- Updated `go.mod` and `go.sum` to reflect dependency changes.
…ntBindAddr` for improved binding logic and IP offset calculation.

Added utility function isDualStack
…log.go` to use new functions for improved modularity and clarity. Removed duplicate implementations of `GetAgentConfig` and `isDualStack`.
…ntConfig`, `GetAgentBindAddr`, and `IsDualStack`. Refactored functions to support mocking for improved testability.
@anilvpatel anilvpatel requested a review from a team as a code owner September 15, 2025 02:35
@github-actions github-actions bot added the theme/cli Flags and documentation for the CLI interface label Sep 15, 2025
Copy link

@yaminisridaran yaminisridaran left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@anilvpatel I have provided my review comments below. Please address the comments.

// everywhere which might make this test brittle but not sure what else
// to do.
GRPC: GRPC{
AgentAddress: "127.0.0.1",

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@anilvpatel please consider using constant instead of hardcode values in multiple places.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Constants help maintainability, but for expected test values, keeping them visible as-is improves clarity.

Base automatically changed from feature/csl-11756-is-agent-ipv4or6 to main September 15, 2025 08:45
@anilvpatel anilvpatel marked this pull request as draft September 18, 2025 04:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
theme/cli Flags and documentation for the CLI interface
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants