clientimplementation

package
v0.12.11 Latest Latest
Warning

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

Go to latest
Published: Feb 11, 2026 License: MPL-2.0 Imports: 36 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	DevPodDebug = "DEVPOD_DEBUG"

	DevPodPlatformOptions = "DEVPOD_PLATFORM_OPTIONS"

	DevPodFlagsUp     = "DEVPOD_FLAGS_UP"
	DevPodFlagsSsh    = "DEVPOD_FLAGS_SSH"
	DevPodFlagsDelete = "DEVPOD_FLAGS_DELETE"
	DevPodFlagsStatus = "DEVPOD_FLAGS_STATUS"
)

Functions

func BuildAgentClient added in v0.10.0

func BuildAgentClient(ctx context.Context, opts BuildAgentClientOptions) (*config2.Result, error)

BuildAgentClient builds an agent client for workspace operations

func DecodeOptionsFromEnv

func DecodeOptionsFromEnv(name string, into any) (bool, error)

func DecodePlatformOptionsFromEnv

func DecodePlatformOptionsFromEnv(into *devpod.PlatformOptions) error

func DeleteMachineFolder

func DeleteMachineFolder(context, machineID string) error

func DeleteWorkspaceFolder

func DeleteWorkspaceFolder(params DeleteWorkspaceFolderParams, log log.Logger) error

func EncodeOptions

func EncodeOptions(options any, name string) map[string]string

func NewMachineClient

func NewMachineClient(devPodConfig *config.Config, provider *provider.ProviderConfig, machine *provider.Machine, log log.Logger) (client.MachineClient, error)

func NewProxyClient

func NewProxyClient(devPodConfig *config.Config, prov *provider.ProviderConfig, workspace *provider.Workspace, log log.Logger) (client.ProxyClient, error)

func NewWorkspaceClient

func NewWorkspaceClient(devPodConfig *config.Config, prov *provider.ProviderConfig, workspace *provider.Workspace, machine *provider.Machine, log log.Logger) (client.WorkspaceClient, error)

func RunCommand

func RunCommand(opts RunCommandOptions) error

func RunCommandWithBinaries

func RunCommandWithBinaries(opts CommandOptions) error

func StartServicesDaemon added in v0.10.0

func StartServicesDaemon(ctx context.Context, opts StartServicesDaemonOptions) error

StartServicesDaemon starts the services daemon for credential forwarding and port forwarding

func StartWait added in v0.10.0

func StartWait(
	ctx context.Context,
	workspaceClient client.WorkspaceClient,
	create bool,
	log log.Logger,
) error

StartWait waits for the workspace to be ready, optionally creating/starting it

Types

type BuildAgentClientOptions added in v0.10.0

type BuildAgentClientOptions struct {
	WorkspaceClient client.WorkspaceClient
	CLIOptions      provider.CLIOptions
	AgentCommand    string
	Log             log.Logger
	TunnelOptions   []tunnelserver.Option
}

BuildAgentClientOptions contains parameters for BuildAgentClient

type CommandOptions added in v0.9.8

type CommandOptions struct {
	Ctx       context.Context
	Name      string
	Command   types.StrArray
	Context   string
	Workspace *provider.Workspace
	Machine   *provider.Machine
	Options   map[string]config.OptionValue
	Config    *provider.ProviderConfig
	ExtraEnv  map[string]string
	Stdin     io.Reader
	Stdout    io.Writer
	Stderr    io.Writer
	Log       log.Logger
}

type DeleteWorkspaceFolderParams added in v0.9.5

type DeleteWorkspaceFolderParams struct {
	Context              string
	WorkspaceID          string
	SSHConfigPath        string
	SSHConfigIncludePath string
}

type RunCommandOptions added in v0.9.8

type RunCommandOptions struct {
	Ctx     context.Context
	Command types.StrArray
	Environ []string
	Stdin   io.Reader
	Stdout  io.Writer
	Stderr  io.Writer
	Log     log.Logger // Optional: for debug mode env var
}

type StartServicesDaemonOptions added in v0.10.0

type StartServicesDaemonOptions struct {
	DevPodConfig *config.Config
	Client       client.DaemonClient
	SSHClient    *ssh.Client
	User         string
	Log          log.Logger
	ForwardPorts bool
	ExtraPorts   []string
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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