Documentation
¶
Index ¶
- Variables
- func ApplyOptions(rc Runner, opts ...RunnerOption) error
- func ConvertToRunnerProject(proj *project.Project) *runnerv1.Project
- func NewPrefixWriter(w io.Writer, prefix string) io.Writer
- func ResolveDirectory(parentDir string, task project.Task) string
- func WithTempSettings(rc Runner, opts []RunnerOption, cb func() error) error
- type LocalRunner
- func (r *LocalRunner) Cleanup(ctx context.Context) error
- func (r *LocalRunner) Clone() Runner
- func (r *LocalRunner) DryRunTask(ctx context.Context, task project.Task, w io.Writer, opts ...RunnerOption) error
- func (r *LocalRunner) GetEnvs(ctx context.Context) ([]string, error)
- func (r *LocalRunner) RunTask(ctx context.Context, task project.Task) error
- type MultiRunner
- type RemoteRunner
- func (r *RemoteRunner) Cleanup(ctx context.Context) error
- func (r *RemoteRunner) Clone() Runner
- func (r *RemoteRunner) DryRunTask(ctx context.Context, task project.Task, w io.Writer, opts ...RunnerOption) error
- func (r *RemoteRunner) GetEnvs(ctx context.Context) ([]string, error)
- func (r *RemoteRunner) GetSessionID() string
- func (r *RemoteRunner) RunTask(ctx context.Context, task project.Task) error
- type Runner
- type RunnerOption
- func WithCleanupSession(cleanup bool) RunnerOption
- func WithCustomShell(customShell string) RunnerOption
- func WithDir(dir string) RunnerOption
- func WithEnableBackgroundProcesses(enableBackground bool) RunnerOption
- func WithEnvStoreType(EnvStoreType runnerv1.SessionEnvStoreType) RunnerOption
- func WithEnvs(envs []string) RunnerOption
- func WithInsecure(insecure bool) RunnerOption
- func WithLogger(logger *zap.Logger) RunnerOption
- func WithProject(proj *project.Project) RunnerOption
- func WithSession(s *runner.Session) RunnerOption
- func WithSessionID(id string) RunnerOption
- func WithSessionStrategy(strategy runnerv1.SessionStrategy) RunnerOption
- func WithStderr(stderr io.Writer) RunnerOption
- func WithStderrTransform(op func(io.Writer) io.Writer) RunnerOption
- func WithStdin(stdin io.Reader) RunnerOption
- func WithStdinTransform(op func(io.Reader) (io.Reader, error)) RunnerOption
- func WithStdout(stdout io.Writer) RunnerOption
- func WithStdoutTransform(op func(io.Writer) io.Writer) RunnerOption
- func WithTLSDir(tlsDir string) RunnerOption
- func WithinShellMaybe() RunnerOption
- func WrapWithCancelReader() RunnerOption
- type RunnerSettings
Constants ¶
This section is empty.
Variables ¶
View Source
var ErrRunnerClientUnimplemented = fmt.Errorf("method unimplemented")
Functions ¶
func ApplyOptions ¶
func ApplyOptions(rc Runner, opts ...RunnerOption) error
func WithTempSettings ¶
func WithTempSettings(rc Runner, opts []RunnerOption, cb func() error) error
Types ¶
type LocalRunner ¶
type LocalRunner struct { *RunnerSettings // contains filtered or unexported fields }
func NewLocalRunner ¶
func NewLocalRunner(opts ...RunnerOption) (*LocalRunner, error)
func (*LocalRunner) Clone ¶
func (r *LocalRunner) Clone() Runner
func (*LocalRunner) DryRunTask ¶
func (r *LocalRunner) DryRunTask(ctx context.Context, task project.Task, w io.Writer, opts ...RunnerOption) error
type MultiRunner ¶
type RemoteRunner ¶
type RemoteRunner struct { *RunnerSettings // contains filtered or unexported fields }
func NewRemoteRunner ¶
func NewRemoteRunner(ctx context.Context, addr string, opts ...RunnerOption) (*RemoteRunner, error)
func (*RemoteRunner) Clone ¶
func (r *RemoteRunner) Clone() Runner
func (*RemoteRunner) DryRunTask ¶
func (r *RemoteRunner) DryRunTask(ctx context.Context, task project.Task, w io.Writer, opts ...RunnerOption) error
func (*RemoteRunner) GetEnvs ¶
func (r *RemoteRunner) GetEnvs(ctx context.Context) ([]string, error)
func (*RemoteRunner) GetSessionID ¶ added in v3.2.3
func (r *RemoteRunner) GetSessionID() string
type Runner ¶
type Runner interface { RunTask(ctx context.Context, task project.Task) error DryRunTask(ctx context.Context, task project.Task, w io.Writer, opts ...RunnerOption) error Cleanup(ctx context.Context) error Clone() Runner GetEnvs(ctx context.Context) ([]string, error) // contains filtered or unexported methods }
type RunnerOption ¶
func WithCleanupSession ¶
func WithCleanupSession(cleanup bool) RunnerOption
func WithCustomShell ¶
func WithCustomShell(customShell string) RunnerOption
func WithDir ¶
func WithDir(dir string) RunnerOption
func WithEnableBackgroundProcesses ¶
func WithEnableBackgroundProcesses(enableBackground bool) RunnerOption
func WithEnvStoreType ¶ added in v3.2.3
func WithEnvStoreType(EnvStoreType runnerv1.SessionEnvStoreType) RunnerOption
func WithEnvs ¶
func WithEnvs(envs []string) RunnerOption
func WithInsecure ¶
func WithInsecure(insecure bool) RunnerOption
func WithLogger ¶
func WithLogger(logger *zap.Logger) RunnerOption
func WithProject ¶
func WithProject(proj *project.Project) RunnerOption
func WithSession ¶
func WithSession(s *runner.Session) RunnerOption
func WithSessionID ¶
func WithSessionID(id string) RunnerOption
func WithSessionStrategy ¶
func WithSessionStrategy(strategy runnerv1.SessionStrategy) RunnerOption
func WithStderr ¶
func WithStderr(stderr io.Writer) RunnerOption
func WithStderrTransform ¶
func WithStderrTransform(op func(io.Writer) io.Writer) RunnerOption
func WithStdin ¶
func WithStdin(stdin io.Reader) RunnerOption
func WithStdinTransform ¶
func WithStdout ¶
func WithStdout(stdout io.Writer) RunnerOption
func WithStdoutTransform ¶
func WithStdoutTransform(op func(io.Writer) io.Writer) RunnerOption
func WithTLSDir ¶
func WithTLSDir(tlsDir string) RunnerOption
func WithinShellMaybe ¶
func WithinShellMaybe() RunnerOption
func WrapWithCancelReader ¶
func WrapWithCancelReader() RunnerOption
type RunnerSettings ¶
type RunnerSettings struct {
// contains filtered or unexported fields
}
func (*RunnerSettings) Clone ¶
func (rs *RunnerSettings) Clone() *RunnerSettings
Click to show internal directories.
Click to hide internal directories.