Documentation
¶
Index ¶
- Variables
- func New() compose.Engine
- func ParseParams(ctx compose.Context, task Task) (*micheline.Prim, error)
- func ParseScript(ctx compose.Context, task Task) (*micheline.Script, error)
- func RegisterTask(typ string, fn TaskFactory)
- type Account
- type Code
- type Engine
- type ErrorMode
- type Params
- type Patch
- type Pipeline
- type PipelineList
- type Script
- type Spec
- type Storage
- type Task
- type TaskBuilder
- type TaskFactory
- type ValueSource
- type WaitMode
Constants ¶
This section is empty.
Variables ¶
View Source
var (
VERSION = "alpha"
)
Functions ¶
func RegisterTask ¶
func RegisterTask(typ string, fn TaskFactory)
Types ¶
type Code ¶
type Code struct {
ValueSource `yaml:",inline"`
}
type Params ¶
type Params struct {
ValueSource `yaml:",inline"`
Entrypoint string `yaml:"entrypoint"`
Args any `yaml:"args,omitempty"`
Patch []Patch `yaml:"patch,omitempty"`
}
type Patch ¶
type PipelineList ¶
type PipelineList []Pipeline
func (PipelineList) MarshalYAML ¶
func (l PipelineList) MarshalYAML() (any, error)
func (*PipelineList) UnmarshalYAML ¶
func (l *PipelineList) UnmarshalYAML(node *yaml.Node) error
type Script ¶
type Script struct {
ValueSource `yaml:",inline"`
Code *Code `yaml:"code,omitempty"`
Storage *Storage `yaml:"storage,omitempty"`
}
type Spec ¶
type Spec struct {
Version string `yaml:"version"`
Accounts []Account `yaml:"accounts,omitempty"`
Variables map[string]string `yaml:"variables,omitempty"`
Pipelines PipelineList `yaml:"pipelines"`
}
type Storage ¶
type Storage struct {
ValueSource `yaml:",inline"`
Args any `yaml:"args,omitempty"`
Patch []Patch `yaml:"patch,omitempty"`
}
type Task ¶
type Task struct {
Type string `yaml:"task"`
Alias string `yaml:"alias,omitempty"`
Skip bool `yaml:"skip,omitempty"`
Amount uint64 `yaml:"amount,omitempty"`
Script *Script `yaml:"script,omitempty"` // deploy only
Params *Params `yaml:"params,omitempty"` // call only
Source string `yaml:"source,omitempty"`
Destination string `yaml:"destination,omitempty"`
Args map[string]any `yaml:"args,omitempty"` // token_* only
Contents []Task `yaml:"contents,omitempty"` // batch only
WaitMode WaitMode `yaml:"for,omitempty"` // wait only
Value string `yaml:"value,omitempty"` // wait only
Log string `yaml:"log,omitempty"` // log level override
OnError ErrorMode `yaml:"on_error,omitempty"` // how to handle errors: fail|warn|ignore
}
type TaskBuilder ¶
type TaskBuilder interface {
Type() string
Validate(compose.Context, Task) error
Build(compose.Context, Task) (*codec.Op, *rpc.CallOptions, error)
}
func NewTask ¶
func NewTask(typ string) (TaskBuilder, error)
type TaskFactory ¶
type TaskFactory func() TaskBuilder
type ValueSource ¶
type ValueSource struct {
File string `yaml:"file,omitempty"`
Url string `yaml:"url,omitempty"`
Value string `yaml:"value,omitempty"`
}
func (ValueSource) IsUsed ¶
func (v ValueSource) IsUsed() bool
Click to show internal directories.
Click to hide internal directories.