trireme-lib: go.aporeto.io/trireme-lib/controller/internal/processmon Index | Files | Directories

package processmon

import "go.aporeto.io/trireme-lib/controller/internal/processmon"

Package processmon is to manage and monitor remote enforcers.

Index

Package Files

interfaces.go processmon.go

type ProcessManager Uses

type ProcessManager interface {
    KillRemoteEnforcer(contextID string, force bool) error
    LaunchRemoteEnforcer(contextID string, refPid int, refNsPath string, arg string, statssecret string, procMountPoint string) (bool, error)
}

ProcessManager interface exposes methods implemented by a processmon

func New Uses

func New(ctx context.Context, p *env.RemoteParameters, c chan *policy.RuntimeError, r rpcwrapper.RPCClient) ProcessManager

New is a method to create a new remote process monitor.

type RemoteMonitor Uses

type RemoteMonitor struct {
    sync.Mutex
    // contains filtered or unexported fields
}

RemoteMonitor is an instance of processMonitor

func (*RemoteMonitor) KillRemoteEnforcer Uses

func (p *RemoteMonitor) KillRemoteEnforcer(contextID string, force bool) error

KillRemoteEnforcer sends a rpc to the process to exit failing which it will kill the process

func (*RemoteMonitor) LaunchRemoteEnforcer Uses

func (p *RemoteMonitor) LaunchRemoteEnforcer(
    contextID string,
    refPid int,
    refNSPath string,
    arg string,
    statsServerSecret string,
    procMountPoint string,
) (bool, error)

LaunchRemoteEnforcer prepares the environment and launches the process. If the process is already launched, it will notify the caller, so that it can avoid any new initialization.

Directories

PathSynopsis
mockprocessmonPackage mockprocessmon is a generated GoMock package.
testbinary

Package processmon imports 21 packages (graph) and is imported by 2 packages. Updated 2019-06-12. Refresh now. Tools for package owners.