Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion cmd/opampsupervisor/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ import (
"log"
"os"
"os/signal"
"syscall"

"github.com/open-telemetry/opentelemetry-collector-contrib/cmd/opampsupervisor/supervisor"
"github.com/open-telemetry/opentelemetry-collector-contrib/cmd/opampsupervisor/supervisor/config"
Expand Down Expand Up @@ -46,7 +47,7 @@ func runInteractive() error {
}

interrupt := make(chan os.Signal, 1)
signal.Notify(interrupt, os.Interrupt)
signal.Notify(interrupt, os.Interrupt, syscall.SIGTERM)
<-interrupt
supervisor.Shutdown()

Expand Down
20 changes: 20 additions & 0 deletions cmd/opampsupervisor/supervisor/commander/commander_aix.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

//go:build aix

package commander

import (
"os"
"syscall"
)

func sendShutdownSignal(process *os.Process) error {
return process.Signal(syscall.SIGTERM)
}

func sysProcAttrs() *syscall.SysProcAttr {
// On non-windows systems, no extra attributes are needed.
return nil
}
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// Copyright The OpenTelemetry Authors
// SPDX-License-Identifier: Apache-2.0

//go:build !windows
//go:build !windows && !aix

package commander

Expand Down
6 changes: 6 additions & 0 deletions cmd/opampsupervisor/supervisor/templates/nooppipeline.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,9 @@ service:
traces:
receivers: [nop]
exporters: [nop]

telemetry:
# Disable agents own telemetry to avoid port binding collisions for port 8888. Bindplane
# will enable metrics and configure the port when a configuration is pushed to the agent.
metrics:
level: none
6 changes: 6 additions & 0 deletions cmd/opampsupervisor/supervisor/templates/opampextension.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,9 @@ extensions:

service:
extensions: [opamp]

telemetry:
# Disable agents own telemetry to avoid port binding collisions for port 8888. Bindplane
# will enable metrics and configure the port when a configuration is pushed to the agent.
metrics:
level: none