Skip to content

Commit

Permalink
CLI: Expose debug port if the service is enabled (#506)
Browse files Browse the repository at this point in the history
  • Loading branch information
ronenh authored Dec 3, 2024
1 parent c15bcd6 commit 75f41df
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions pkg/cc/config/loader.go
Original file line number Diff line number Diff line change
Expand Up @@ -168,6 +168,14 @@ func (l *Loader) GetPorts() ([]string, error) {
portMap[port] = true
}

if l.Configuration.DebugService.Enabled && l.Configuration.DebugService.ListenAddress != "" {
port, err := getPortFromAddress(l.Configuration.DebugService.ListenAddress)
if err != nil {
return nil, err
}
portMap[port] = true
}

for _, value := range l.Configuration.APIConfig.Services {
if value.GRPC.ListenAddress != "" {
port, err := getPortFromAddress(value.GRPC.ListenAddress)
Expand Down

0 comments on commit 75f41df

Please sign in to comment.