modulerunner

package
v0.1.0-alpha.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 31, 2023 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ModuleRunner

type ModuleRunner struct {
	// contains filtered or unexported fields
}

func NewModuleRunner

func NewModuleRunner(config *worker.RunnerConfig) *ModuleRunner

func (*ModuleRunner) Monitor

func (mr *ModuleRunner) Monitor(ctx context.Context, input MonitorInput) (string, error)

func (*ModuleRunner) Provision

func (mqc *ModuleRunner) Provision(ctx workflow.Context, input RunInput) (string, error)

func (*ModuleRunner) Run

func (mr *ModuleRunner) Run(ctx context.Context, input RunInput) (string, error)

func (*ModuleRunner) RunMonitor

func (mqc *ModuleRunner) RunMonitor(ctx workflow.Context, input MonitorInput) (string, error)

type MonitorIDAndKind

type MonitorIDAndKind struct {
	ID   string
	Kind models.ModuleMonitorKind
}

type MonitorInput

type MonitorInput struct {
	ModuleMonitorID string
	Kind            models.ModuleMonitorKind
	Opts            *provisioner.ProvisionOpts
}

type MonitorOutput

type MonitorOutput struct {
	Status      models.MonitorResultStatus
	Severity    models.MonitorResultSeverity
	Title       string
	Description string
}

type RunInput

type RunInput struct {
	// A list of monitors to trigger before the run
	BeforeMonitors []MonitorIDAndKind

	// A list of monitors to trigger after the run
	AfterMonitors []MonitorIDAndKind

	Kind models.ModuleRunKind
	Opts *provisioner.ProvisionOpts
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL