action

package
v0.1.8 Latest Latest
Warning

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

Go to latest
Published: Jan 7, 2023 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Action

type Action struct {
	Name    string `yaml:"name" required:"true"`
	Command string `yaml:"command" required:"true"`
	Code    int    `yaml:"code" default:"0"`
	Cron    string `yaml:"cron" default:"* * * * *"`
	On      On     `yaml:"on" requred:"true"`
}

func (*Action) Execute

func (a *Action) Execute() error

func (*Action) LogError

func (a *Action) LogError(value string)

func (*Action) LogInfo

func (a *Action) LogInfo(value string)

func (*Action) Validate

func (a *Action) Validate() error

type On

type On struct {
	Start   string `yaml:"start"`
	Success string `yaml:"success" required:"true"`
	Failure string `yaml:"failure"`
}

func (*On) Validate

func (o *On) Validate() error

Jump to

Keyboard shortcuts

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