agent

package
v3.38.1 Latest Latest
Warning

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

Go to latest
Published: Apr 24, 2026 License: MIT Imports: 26 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type InstallCmd added in v3.33.0

type InstallCmd struct {
	Version     string `help:"Specify an agent version to install" default:"latest"`
	Dest        string `help:"Destination directory for the binary" type:"path"`
	ClusterUUID string `help:"Cluster UUID to create the agent token on (default: the \"Default\" cluster)" name:"cluster-uuid" optional:""`
	NoToken     bool   `help:"Skip creating an agent token and config file" name:"no-token"`
	ConfigPath  string `help:"Path to write the agent config file" type:"path"`
}

InstallCmd allows users to define which agent version they want to install We will take care of OS/arch in the command itself

func (*InstallCmd) Help added in v3.33.0

func (i *InstallCmd) Help() string

func (*InstallCmd) Run added in v3.33.0

func (i *InstallCmd) Run(kongCtx *kong.Context, globals cli.GlobalFlags) error

type ListCmd

type ListCmd struct {
	Name     string   `help:"Filter agents by their name"`
	Version  string   `help:"Filter agents by their version"`
	Hostname string   `help:"Filter agents by their hostname"`
	State    string   `help:"Filter agents by state (running, idle, paused)"`
	Tags     []string `help:"Filter agents by tags"`
	PerPage  int      `help:"Number of agents per page" default:"30"`
	Limit    int      `help:"Maximum number of agents to return" default:"100"`
	output.OutputFlags
}

func (*ListCmd) Help

func (c *ListCmd) Help() string

func (*ListCmd) Run

func (c *ListCmd) Run(kongCtx *kong.Context, globals cli.GlobalFlags) error

type PauseCmd

type PauseCmd struct {
	AgentID          string `arg:"" help:"Agent ID to pause"`
	Note             string `help:"A descriptive note to record why the agent is paused"`
	TimeoutInMinutes int    `help:"Timeout after which the agent is automatically resumed, in minutes" default:"5"`
}

func (*PauseCmd) Help

func (c *PauseCmd) Help() string

func (*PauseCmd) Run

func (c *PauseCmd) Run(kongCtx *kong.Context, globals cli.GlobalFlags) error

type ResumeCmd

type ResumeCmd struct {
	AgentID string `arg:"" help:"Agent ID to resume"`
}

func (*ResumeCmd) Help

func (c *ResumeCmd) Help() string

func (*ResumeCmd) Run

func (c *ResumeCmd) Run(kongCtx *kong.Context, globals cli.GlobalFlags) error

type RunCmd added in v3.33.0

type RunCmd struct {
	Version     string `help:"Specify an agent version to run" default:"latest"`
	ClusterUUID string `help:"Cluster UUID to create the agent token on (default: the \"Default\" cluster)" name:"cluster-uuid" optional:""`
	Queue       string `help:"Queue for the agent to listen on" default:"default"`
}

RunCmd spins up an ephemeral buildkite-agent attached to a cluster.

func (*RunCmd) Help added in v3.33.0

func (r *RunCmd) Help() string

func (*RunCmd) Run added in v3.33.0

func (r *RunCmd) Run(kongCtx *kong.Context, globals cli.GlobalFlags) error

type StopCmd

type StopCmd struct {
	Agents []string `arg:"" optional:"" help:"Agent IDs to stop"`
	Force  bool     `help:"Force stop the agent. Terminating any jobs in progress"`
	Limit  int64    `help:"Limit parallel API requests" short:"l" default:"5"`
}

func (*StopCmd) Help

func (c *StopCmd) Help() string

func (*StopCmd) Run

func (c *StopCmd) Run(kongCtx *kong.Context, globals cli.GlobalFlags) error

type ViewCmd

type ViewCmd struct {
	Agent string `arg:"" help:"Agent ID to view"`
	Web   bool   `help:"Open agent in a browser" short:"w"`
	output.OutputFlags
}

func (*ViewCmd) Help

func (c *ViewCmd) Help() string

func (*ViewCmd) Run

func (c *ViewCmd) Run(kongCtx *kong.Context, globals cli.GlobalFlags) error

Jump to

Keyboard shortcuts

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