program

package
v2.5.0 Latest Latest
Warning

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

Go to latest
Published: Mar 21, 2023 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ProgramBinPath     = "/var/lib/baetyl/bin"
	ProgramEntryYaml   = "program.yml" // in program package to specify entry
	ProgramServiceYaml = "service.yml"
	ProgramConfYaml    = "/etc/baetyl/conf.yml"
)

Variables

This section is empty.

Functions

func Run

func Run(wd string) error

Types

type Config

type Config struct {
	Name        string `yaml:"name" json:"name" validate:"nonzero"`
	DisplayName string `yaml:"displayName" json:"displayName"`
	Description string `yaml:"description" json:"description"`

	Dir  string   `yaml:"dir" json:"dir"`
	Exec string   `yaml:"exec" json:"exec"`
	Args []string `yaml:"args" json:"args"`
	Env  []string `yaml:"env" json:"env"`

	Logger log.Config `yaml:"logger" json:"logger"`
}

Config is the program config.

type Entry

type Entry struct {
	Entry string `yaml:"entry" json:"entry" validate:"nonzero"`
}

type Program

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

func (*Program) Start

func (p *Program) Start(s service.Service) error

func (*Program) Stop

func (p *Program) Stop(s service.Service) error

Jump to

Keyboard shortcuts

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