Documentation
¶
Index ¶
- Variables
- type Cancel
- type CancelKind
- type Exit
- type Frame
- func (*Frame) Descriptor() ([]byte, []int)deprecated
- func (x *Frame) GetBody() isFrame_Body
- func (x *Frame) GetCancel() *Cancel
- func (x *Frame) GetExit() *Exit
- func (x *Frame) GetHello() *Hello
- func (x *Frame) GetJobResult() *JobResult
- func (x *Frame) GetLog() *Log
- func (x *Frame) GetOutput() *Output
- func (x *Frame) GetRun() *Run
- func (x *Frame) GetStepCompleted() *StepCompleted
- func (x *Frame) GetStepStarted() *StepStarted
- func (*Frame) ProtoMessage()
- func (x *Frame) ProtoReflect() protoreflect.Message
- func (x *Frame) Reset()
- func (x *Frame) String() string
- type Frame_Cancel
- type Frame_Exit
- type Frame_Hello
- type Frame_JobResult
- type Frame_Log
- type Frame_Output
- type Frame_Run
- type Frame_StepCompleted
- type Frame_StepStarted
- type Hello
- type JobResult
- func (*JobResult) Descriptor() ([]byte, []int)deprecated
- func (x *JobResult) GetConclusion() StepConclusion
- func (x *JobResult) GetError() string
- func (x *JobResult) GetOutputs() map[string]string
- func (x *JobResult) GetRunnerShutdown() bool
- func (*JobResult) ProtoMessage()
- func (x *JobResult) ProtoReflect() protoreflect.Message
- func (x *JobResult) Reset()
- func (x *JobResult) String() string
- type JobSpec
- func (*JobSpec) Descriptor() ([]byte, []int)deprecated
- func (x *JobSpec) GetContexts() string
- func (x *JobSpec) GetDeadlineMs() int64
- func (x *JobSpec) GetDebug() bool
- func (x *JobSpec) GetJobKey() string
- func (x *JobSpec) GetMatrix() string
- func (x *JobSpec) GetRepo() string
- func (x *JobSpec) GetRunnerEnvironment() string
- func (x *JobSpec) GetRunnerName() string
- func (x *JobSpec) GetRunnerVersion() string
- func (x *JobSpec) GetTimeoutMinutes() int32
- func (x *JobSpec) GetWorkflowPath() string
- func (x *JobSpec) GetWorkflowYaml() string
- func (*JobSpec) ProtoMessage()
- func (x *JobSpec) ProtoReflect() protoreflect.Message
- func (x *JobSpec) Reset()
- func (x *JobSpec) String() string
- type Log
- func (*Log) Descriptor() ([]byte, []int)deprecated
- func (x *Log) GetContinued() bool
- func (x *Log) GetStep() int32
- func (x *Log) GetText() string
- func (x *Log) GetUnixNano() int64
- func (*Log) ProtoMessage()
- func (x *Log) ProtoReflect() protoreflect.Message
- func (x *Log) Reset()
- func (x *Log) String() string
- type Output
- func (*Output) Descriptor() ([]byte, []int)deprecated
- func (x *Output) GetData() []byte
- func (x *Output) GetStream() StreamKind
- func (x *Output) GetUnixNano() int64
- func (*Output) ProtoMessage()
- func (x *Output) ProtoReflect() protoreflect.Message
- func (x *Output) Reset()
- func (x *Output) String() string
- type Run
- type StepCompleted
- func (*StepCompleted) Descriptor() ([]byte, []int)deprecated
- func (x *StepCompleted) GetConclusion() StepConclusion
- func (x *StepCompleted) GetName() string
- func (x *StepCompleted) GetNumber() int32
- func (x *StepCompleted) GetUnixNano() int64
- func (*StepCompleted) ProtoMessage()
- func (x *StepCompleted) ProtoReflect() protoreflect.Message
- func (x *StepCompleted) Reset()
- func (x *StepCompleted) String() string
- type StepConclusion
- func (StepConclusion) Descriptor() protoreflect.EnumDescriptor
- func (x StepConclusion) Enum() *StepConclusion
- func (StepConclusion) EnumDescriptor() ([]byte, []int)deprecated
- func (x StepConclusion) Number() protoreflect.EnumNumber
- func (x StepConclusion) String() string
- func (StepConclusion) Type() protoreflect.EnumType
- type StepStarted
- func (*StepStarted) Descriptor() ([]byte, []int)deprecated
- func (x *StepStarted) GetName() string
- func (x *StepStarted) GetNumber() int32
- func (x *StepStarted) GetUnixNano() int64
- func (*StepStarted) ProtoMessage()
- func (x *StepStarted) ProtoReflect() protoreflect.Message
- func (x *StepStarted) Reset()
- func (x *StepStarted) String() string
- type StreamKind
Constants ¶
This section is empty.
Variables ¶
var ( StreamKind_name = map[int32]string{ 0: "STREAM_KIND_UNSPECIFIED", 1: "STREAM_KIND_STDOUT", 2: "STREAM_KIND_STDERR", } StreamKind_value = map[string]int32{ "STREAM_KIND_UNSPECIFIED": 0, "STREAM_KIND_STDOUT": 1, "STREAM_KIND_STDERR": 2, } )
Enum value maps for StreamKind.
var ( CancelKind_name = map[int32]string{ 0: "CANCEL_KIND_UNSPECIFIED", 1: "CANCEL_KIND_USER", 2: "CANCEL_KIND_TIMEOUT", 3: "CANCEL_KIND_SHUTDOWN", } CancelKind_value = map[string]int32{ "CANCEL_KIND_UNSPECIFIED": 0, "CANCEL_KIND_USER": 1, "CANCEL_KIND_TIMEOUT": 2, "CANCEL_KIND_SHUTDOWN": 3, } )
Enum value maps for CancelKind.
var ( StepConclusion_name = map[int32]string{ 0: "STEP_CONCLUSION_UNSPECIFIED", 1: "STEP_CONCLUSION_SUCCESS", 2: "STEP_CONCLUSION_FAILURE", 3: "STEP_CONCLUSION_CANCELLED", 4: "STEP_CONCLUSION_SKIPPED", 5: "STEP_CONCLUSION_TIMED_OUT", } StepConclusion_value = map[string]int32{ "STEP_CONCLUSION_UNSPECIFIED": 0, "STEP_CONCLUSION_SUCCESS": 1, "STEP_CONCLUSION_FAILURE": 2, "STEP_CONCLUSION_CANCELLED": 3, "STEP_CONCLUSION_SKIPPED": 4, "STEP_CONCLUSION_TIMED_OUT": 5, } )
Enum value maps for StepConclusion.
var File_exec_proto protoreflect.FileDescriptor
Functions ¶
This section is empty.
Types ¶
type Cancel ¶
type Cancel struct {
// reason is for the job log and diagnostics ("cancelled by the user",
// "job timeout", ...); it never changes the behaviour.
Reason string `protobuf:"bytes,1,opt,name=reason,proto3" json:"reason,omitempty"`
// kind tells the job executor how the job ends: cancelled, timed out, or
// cancelled because the runner shuts down. The stub executor ignores it.
Kind CancelKind `protobuf:"varint,2,opt,name=kind,proto3,enum=ermite.runner.exec.v1.CancelKind" json:"kind,omitempty"`
// contains filtered or unexported fields
}
Cancel asks the executor to stop the running script. The executor escalates like the official runner: SIGINT to the script's process group at once, SIGTERM 7.5 s later, SIGKILL 2.5 s after that.
func (*Cancel) Descriptor
deprecated
func (*Cancel) GetKind ¶
func (x *Cancel) GetKind() CancelKind
func (*Cancel) ProtoMessage ¶
func (*Cancel) ProtoMessage()
func (*Cancel) ProtoReflect ¶
func (x *Cancel) ProtoReflect() protoreflect.Message
type CancelKind ¶
type CancelKind int32
const ( CancelKind_CANCEL_KIND_UNSPECIFIED CancelKind = 0 // same as USER CancelKind_CANCEL_KIND_USER CancelKind = 1 CancelKind_CANCEL_KIND_TIMEOUT CancelKind = 2 CancelKind_CANCEL_KIND_SHUTDOWN CancelKind = 3 )
func (CancelKind) Descriptor ¶
func (CancelKind) Descriptor() protoreflect.EnumDescriptor
func (CancelKind) Enum ¶
func (x CancelKind) Enum() *CancelKind
func (CancelKind) EnumDescriptor
deprecated
func (CancelKind) EnumDescriptor() ([]byte, []int)
Deprecated: Use CancelKind.Descriptor instead.
func (CancelKind) Number ¶
func (x CancelKind) Number() protoreflect.EnumNumber
func (CancelKind) String ¶
func (x CancelKind) String() string
func (CancelKind) Type ¶
func (CancelKind) Type() protoreflect.EnumType
type Exit ¶
type Exit struct {
Code int32 `protobuf:"varint,1,opt,name=code,proto3" json:"code,omitempty"`
Error string `protobuf:"bytes,2,opt,name=error,proto3" json:"error,omitempty"` // set when the executor failed to run the script at all
// contains filtered or unexported fields
}
func (*Exit) Descriptor
deprecated
func (*Exit) ProtoMessage ¶
func (*Exit) ProtoMessage()
func (*Exit) ProtoReflect ¶
func (x *Exit) ProtoReflect() protoreflect.Message
type Frame ¶
type Frame struct {
// Types that are valid to be assigned to Body:
//
// *Frame_Hello
// *Frame_Run
// *Frame_Output
// *Frame_Exit
// *Frame_Cancel
// *Frame_StepStarted
// *Frame_StepCompleted
// *Frame_Log
// *Frame_JobResult
Body isFrame_Body `protobuf_oneof:"body"`
// contains filtered or unexported fields
}
Frame is the only message on the stream.
func (*Frame) Descriptor
deprecated
func (*Frame) GetJobResult ¶
func (*Frame) GetStepCompleted ¶
func (x *Frame) GetStepCompleted() *StepCompleted
func (*Frame) GetStepStarted ¶
func (x *Frame) GetStepStarted() *StepStarted
func (*Frame) ProtoMessage ¶
func (*Frame) ProtoMessage()
func (*Frame) ProtoReflect ¶
func (x *Frame) ProtoReflect() protoreflect.Message
type Frame_Cancel ¶
type Frame_Cancel struct {
Cancel *Cancel `protobuf:"bytes,5,opt,name=cancel,proto3,oneof"` // host -> executor
}
type Frame_Exit ¶
type Frame_Exit struct {
Exit *Exit `protobuf:"bytes,4,opt,name=exit,proto3,oneof"` // executor -> host, last frame
}
type Frame_Hello ¶
type Frame_Hello struct {
Hello *Hello `protobuf:"bytes,1,opt,name=hello,proto3,oneof"` // executor -> host, first frame
}
type Frame_JobResult ¶
type Frame_JobResult struct {
JobResult *JobResult `protobuf:"bytes,9,opt,name=job_result,json=jobResult,proto3,oneof"` // executor -> host, before Exit
}
type Frame_Log ¶
type Frame_Log struct {
Log *Log `protobuf:"bytes,8,opt,name=log,proto3,oneof"` // executor -> host
}
type Frame_Output ¶
type Frame_Output struct {
Output *Output `protobuf:"bytes,3,opt,name=output,proto3,oneof"` // executor -> host
}
type Frame_Run ¶
type Frame_Run struct {
Run *Run `protobuf:"bytes,2,opt,name=run,proto3,oneof"` // host -> executor, after Hello
}
type Frame_StepCompleted ¶
type Frame_StepCompleted struct {
StepCompleted *StepCompleted `protobuf:"bytes,7,opt,name=step_completed,json=stepCompleted,proto3,oneof"` // executor -> host
}
type Frame_StepStarted ¶
type Frame_StepStarted struct {
StepStarted *StepStarted `protobuf:"bytes,6,opt,name=step_started,json=stepStarted,proto3,oneof"` // executor -> host
}
type Hello ¶
type Hello struct {
Version string `protobuf:"bytes,1,opt,name=version,proto3" json:"version,omitempty"` // runner version of the executor
Sandbox string `protobuf:"bytes,2,opt,name=sandbox,proto3" json:"sandbox,omitempty"` // "vm" or "container"
Hostname string `protobuf:"bytes,3,opt,name=hostname,proto3" json:"hostname,omitempty"`
// contains filtered or unexported fields
}
func (*Hello) Descriptor
deprecated
func (*Hello) GetHostname ¶
func (*Hello) GetSandbox ¶
func (*Hello) GetVersion ¶
func (*Hello) ProtoMessage ¶
func (*Hello) ProtoMessage()
func (*Hello) ProtoReflect ¶
func (x *Hello) ProtoReflect() protoreflect.Message
type JobResult ¶
type JobResult struct {
Conclusion StepConclusion `protobuf:"varint,1,opt,name=conclusion,proto3,enum=ermite.runner.exec.v1.StepConclusion" json:"conclusion,omitempty"`
Outputs map[string]string `` /* 141-byte string literal not displayed */
Error string `protobuf:"bytes,3,opt,name=error,proto3" json:"error,omitempty"`
RunnerShutdown bool `protobuf:"varint,4,opt,name=runner_shutdown,json=runnerShutdown,proto3" json:"runner_shutdown,omitempty"`
// contains filtered or unexported fields
}
JobResult is the outcome of the job; Exit follows.
func (*JobResult) Descriptor
deprecated
func (*JobResult) GetConclusion ¶
func (x *JobResult) GetConclusion() StepConclusion
func (*JobResult) GetOutputs ¶
func (*JobResult) GetRunnerShutdown ¶
func (*JobResult) ProtoMessage ¶
func (*JobResult) ProtoMessage()
func (*JobResult) ProtoReflect ¶
func (x *JobResult) ProtoReflect() protoreflect.Message
type JobSpec ¶
type JobSpec struct {
WorkflowPath string `protobuf:"bytes,1,opt,name=workflow_path,json=workflowPath,proto3" json:"workflow_path,omitempty"`
WorkflowYaml string `protobuf:"bytes,2,opt,name=workflow_yaml,json=workflowYaml,proto3" json:"workflow_yaml,omitempty"`
JobKey string `protobuf:"bytes,3,opt,name=job_key,json=jobKey,proto3" json:"job_key,omitempty"`
Matrix string `protobuf:"bytes,4,opt,name=matrix,proto3" json:"matrix,omitempty"` // JSON object
Contexts string `protobuf:"bytes,5,opt,name=contexts,proto3" json:"contexts,omitempty"` // JSON object
Repo string `protobuf:"bytes,6,opt,name=repo,proto3" json:"repo,omitempty"` // repository name
TimeoutMinutes int32 `protobuf:"varint,7,opt,name=timeout_minutes,json=timeoutMinutes,proto3" json:"timeout_minutes,omitempty"`
RunnerName string `protobuf:"bytes,8,opt,name=runner_name,json=runnerName,proto3" json:"runner_name,omitempty"`
RunnerVersion string `protobuf:"bytes,9,opt,name=runner_version,json=runnerVersion,proto3" json:"runner_version,omitempty"`
// runner_environment is the runner.environment value ("github-hosted" or "self-hosted").
RunnerEnvironment string `protobuf:"bytes,10,opt,name=runner_environment,json=runnerEnvironment,proto3" json:"runner_environment,omitempty"`
Debug bool `protobuf:"varint,11,opt,name=debug,proto3" json:"debug,omitempty"` // ACTIONS_STEP_DEBUG
// deadline_ms is what is left of the job timeout when the host sends this
// Run, in milliseconds: the timeout counts from the moment the host received
// the job (runner.proto: Job.timeout_minutes), not from the start of the
// executor, and booting the sandbox takes time. 0 means "use
// timeout_minutes from now".
DeadlineMs int64 `protobuf:"varint,12,opt,name=deadline_ms,json=deadlineMs,proto3" json:"deadline_ms,omitempty"`
// contains filtered or unexported fields
}
JobSpec is the job to run: the fields of the job that ermite handed to the host process, minus the tokens (the sandbox never sees them).
func (*JobSpec) Descriptor
deprecated
func (*JobSpec) GetContexts ¶
func (*JobSpec) GetDeadlineMs ¶
func (*JobSpec) GetRunnerEnvironment ¶
func (*JobSpec) GetRunnerName ¶
func (*JobSpec) GetRunnerVersion ¶
func (*JobSpec) GetTimeoutMinutes ¶
func (*JobSpec) GetWorkflowPath ¶
func (*JobSpec) GetWorkflowYaml ¶
func (*JobSpec) ProtoMessage ¶
func (*JobSpec) ProtoMessage()
func (*JobSpec) ProtoReflect ¶
func (x *JobSpec) ProtoReflect() protoreflect.Message
type Log ¶
type Log struct {
Step int32 `protobuf:"varint,1,opt,name=step,proto3" json:"step,omitempty"`
UnixNano int64 `protobuf:"varint,2,opt,name=unix_nano,json=unixNano,proto3" json:"unix_nano,omitempty"`
Text string `protobuf:"bytes,3,opt,name=text,proto3" json:"text,omitempty"`
Continued bool `protobuf:"varint,4,opt,name=continued,proto3" json:"continued,omitempty"`
// contains filtered or unexported fields
}
Log is one line of the job log, without terminator, valid UTF-8. A line of more than 64 KiB is cut by the executor into pieces at character boundaries; every piece but the first has continued set (the AppendLog rule).
func (*Log) Descriptor
deprecated
func (*Log) GetContinued ¶
func (*Log) GetUnixNano ¶
func (*Log) ProtoMessage ¶
func (*Log) ProtoMessage()
func (*Log) ProtoReflect ¶
func (x *Log) ProtoReflect() protoreflect.Message
type Output ¶
type Output struct {
Stream StreamKind `protobuf:"varint,1,opt,name=stream,proto3,enum=ermite.runner.exec.v1.StreamKind" json:"stream,omitempty"`
Data []byte `protobuf:"bytes,2,opt,name=data,proto3" json:"data,omitempty"`
UnixNano int64 `protobuf:"varint,3,opt,name=unix_nano,json=unixNano,proto3" json:"unix_nano,omitempty"`
// contains filtered or unexported fields
}
func (*Output) Descriptor
deprecated
func (*Output) GetStream ¶
func (x *Output) GetStream() StreamKind
func (*Output) GetUnixNano ¶
func (*Output) ProtoMessage ¶
func (*Output) ProtoMessage()
func (*Output) ProtoReflect ¶
func (x *Output) ProtoReflect() protoreflect.Message
type Run ¶
type Run struct {
Script string `protobuf:"bytes,1,opt,name=script,proto3" json:"script,omitempty"`
Env map[string]string `` /* 133-byte string literal not displayed */
Job *JobSpec `protobuf:"bytes,3,opt,name=job,proto3" json:"job,omitempty"`
// contains filtered or unexported fields
}
Run asks the executor to run a script or a job. Without job it is the stub executor of sandbox-check: the script is run with `sh -c`; an empty script means the built-in diagnostics script. With job the executor runs the job like a GitHub Actions runner and reports it with StepStarted, Log, StepCompleted and JobResult frames, then Exit.
func (*Run) Descriptor
deprecated
func (*Run) ProtoMessage ¶
func (*Run) ProtoMessage()
func (*Run) ProtoReflect ¶
func (x *Run) ProtoReflect() protoreflect.Message
type StepCompleted ¶
type StepCompleted struct {
Number int32 `protobuf:"varint,1,opt,name=number,proto3" json:"number,omitempty"`
Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
Conclusion StepConclusion `protobuf:"varint,3,opt,name=conclusion,proto3,enum=ermite.runner.exec.v1.StepConclusion" json:"conclusion,omitempty"`
UnixNano int64 `protobuf:"varint,4,opt,name=unix_nano,json=unixNano,proto3" json:"unix_nano,omitempty"`
// contains filtered or unexported fields
}
func (*StepCompleted) Descriptor
deprecated
func (*StepCompleted) Descriptor() ([]byte, []int)
Deprecated: Use StepCompleted.ProtoReflect.Descriptor instead.
func (*StepCompleted) GetConclusion ¶
func (x *StepCompleted) GetConclusion() StepConclusion
func (*StepCompleted) GetName ¶
func (x *StepCompleted) GetName() string
func (*StepCompleted) GetNumber ¶
func (x *StepCompleted) GetNumber() int32
func (*StepCompleted) GetUnixNano ¶
func (x *StepCompleted) GetUnixNano() int64
func (*StepCompleted) ProtoMessage ¶
func (*StepCompleted) ProtoMessage()
func (*StepCompleted) ProtoReflect ¶
func (x *StepCompleted) ProtoReflect() protoreflect.Message
func (*StepCompleted) Reset ¶
func (x *StepCompleted) Reset()
func (*StepCompleted) String ¶
func (x *StepCompleted) String() string
type StepConclusion ¶
type StepConclusion int32
const ( StepConclusion_STEP_CONCLUSION_UNSPECIFIED StepConclusion = 0 StepConclusion_STEP_CONCLUSION_SUCCESS StepConclusion = 1 StepConclusion_STEP_CONCLUSION_FAILURE StepConclusion = 2 StepConclusion_STEP_CONCLUSION_CANCELLED StepConclusion = 3 StepConclusion_STEP_CONCLUSION_SKIPPED StepConclusion = 4 StepConclusion_STEP_CONCLUSION_TIMED_OUT StepConclusion = 5 // jobs only )
func (StepConclusion) Descriptor ¶
func (StepConclusion) Descriptor() protoreflect.EnumDescriptor
func (StepConclusion) Enum ¶
func (x StepConclusion) Enum() *StepConclusion
func (StepConclusion) EnumDescriptor
deprecated
func (StepConclusion) EnumDescriptor() ([]byte, []int)
Deprecated: Use StepConclusion.Descriptor instead.
func (StepConclusion) Number ¶
func (x StepConclusion) Number() protoreflect.EnumNumber
func (StepConclusion) String ¶
func (x StepConclusion) String() string
func (StepConclusion) Type ¶
func (StepConclusion) Type() protoreflect.EnumType
type StepStarted ¶
type StepStarted struct {
Number int32 `protobuf:"varint,1,opt,name=number,proto3" json:"number,omitempty"`
Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
UnixNano int64 `protobuf:"varint,3,opt,name=unix_nano,json=unixNano,proto3" json:"unix_nano,omitempty"`
// contains filtered or unexported fields
}
Steps are numbered like GitHub's log: "Set up job" is 1, the steps of the workflow follow, "Complete job" is last.
func (*StepStarted) Descriptor
deprecated
func (*StepStarted) Descriptor() ([]byte, []int)
Deprecated: Use StepStarted.ProtoReflect.Descriptor instead.
func (*StepStarted) GetName ¶
func (x *StepStarted) GetName() string
func (*StepStarted) GetNumber ¶
func (x *StepStarted) GetNumber() int32
func (*StepStarted) GetUnixNano ¶
func (x *StepStarted) GetUnixNano() int64
func (*StepStarted) ProtoMessage ¶
func (*StepStarted) ProtoMessage()
func (*StepStarted) ProtoReflect ¶
func (x *StepStarted) ProtoReflect() protoreflect.Message
func (*StepStarted) Reset ¶
func (x *StepStarted) Reset()
func (*StepStarted) String ¶
func (x *StepStarted) String() string
type StreamKind ¶
type StreamKind int32
const ( StreamKind_STREAM_KIND_UNSPECIFIED StreamKind = 0 StreamKind_STREAM_KIND_STDOUT StreamKind = 1 StreamKind_STREAM_KIND_STDERR StreamKind = 2 )
func (StreamKind) Descriptor ¶
func (StreamKind) Descriptor() protoreflect.EnumDescriptor
func (StreamKind) Enum ¶
func (x StreamKind) Enum() *StreamKind
func (StreamKind) EnumDescriptor
deprecated
func (StreamKind) EnumDescriptor() ([]byte, []int)
Deprecated: Use StreamKind.Descriptor instead.
func (StreamKind) Number ¶
func (x StreamKind) Number() protoreflect.EnumNumber
func (StreamKind) String ¶
func (x StreamKind) String() string
func (StreamKind) Type ¶
func (StreamKind) Type() protoreflect.EnumType