ssh

package
v1.7.0 Latest Latest
Warning

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

Go to latest
Published: Oct 21, 2026 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Overview

Package ssh manages servers over the system ssh client, so ~/.ssh/config, agents, keys and jump hosts work exactly as they do in a terminal.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New(_ core.Env, c *spec.Component) (any, error)

Types

type Host

type Host struct {
	Name   string            `yaml:"name"`
	Addr   string            `yaml:"addr"`
	User   string            `yaml:"user"`
	Port   int               `yaml:"port"`
	Key    string            `yaml:"key"`
	Jump   string            `yaml:"jump"`
	Roles  []string          `yaml:"roles"`
	Labels map[string]string `yaml:"labels"`
}

type Options

type Options struct {
	Defaults Host   `yaml:"defaults"`
	Hosts    []Host `yaml:"hosts"`
}

type SSH

type SSH struct {
	// contains filtered or unexported fields
}

func (*SSH) Actions

func (s *SSH) Actions() []core.Action

func (*SSH) Hosts

func (s *SSH) Hosts(ctx context.Context) ([]core.Host, error)

func (*SSH) Shell

func (s *SSH) Shell(ctx context.Context, name string, command []string) (*exec.Cmd, error)

Jump to

Keyboard shortcuts

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