machinescommon

package
v0.10.1 Latest Latest
Warning

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

Go to latest
Published: Dec 23, 2022 License: Apache-2.0 Imports: 16 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

View Source
const (
	FlagFingerprint = "fingerprint"
	FlagHost        = "host"
	FlagPort        = "port"
	FlagAccount     = "account"
	FlagRuntime     = "runtime"
	FlagPlatform    = "platform"

	SelfContainedCalamari = "self-contained"
	MonoCalamari          = "mono"

	LinuxX64   = "linux-x64"
	LinuxArm64 = "linux-arm64"
	LinuxArm   = "linux-arm"
	OsxX64     = "osx-x64"

	DefaultPort = 22
)
View Source
const (
	FlagMachinePolicy = "machine-policy"
)
View Source
const FlagProxy = "proxy"
View Source
const (
	FlagWeb = "web"
)

Variables

View Source
var CommunicationStyleToDeploymentTargetTypeMap = map[string]string{
	"TentaclePassive":           "TentaclePassive",
	"TentacleActive":            "TentacleActive",
	"Ssh":                       "Ssh",
	"OfflineDrop":               "OfflineDrop",
	"AzureWebApp":               "AzureWebApp",
	"AzureCloudService":         "AzureCloudService",
	"AzureServiceFabricCluster": "AzureServiceFabricCluster",
	"Kubernetes":                "Kubernetes",
	"None":                      "CloudRegion",
}
View Source
var CommunicationStyleToDescriptionMap = map[string]string{
	"TentaclePassive":           "Listening Tentacle",
	"TentacleActive":            "Polling Tentacle",
	"Ssh":                       "SSH Connection",
	"OfflineDrop":               "Offline Package Drop",
	"AzureWebApp":               "Azure Web App",
	"AzureCloudService":         "Azure Cloud Service",
	"AzureServiceFabricCluster": "Service Fabric Cluster",
	"Kubernetes":                "Kubernetes Cluster",
	"None":                      "Cloud Region",
	"StepPackage":               "Step Package",
}

Functions

func DoWebForTargets

func DoWebForTargets(target *machines.DeploymentTarget, dependencies *cmd.Dependencies, flags *WebFlags, description string)

func DoWebForWorkerPools added in v0.7.0

func DoWebForWorkerPools(workerPool workerpools.IWorkerPool, dependencies *cmd.Dependencies, flags *WebFlags)

func DoWebForWorkers

func DoWebForWorkers(worker *machines.Worker, dependencies *cmd.Dependencies, flags *WebFlags, description string)

func FindDefaultMachinePolicy added in v0.8.0

func FindDefaultMachinePolicy(getAllMachinePoliciesCallback GetAllMachinePoliciesCallback) (*machines.MachinePolicy, error)

func FindMachinePolicy

func FindMachinePolicy(getAllMachinePoliciesCallback GetAllMachinePoliciesCallback, nameOrId string) (*machines.MachinePolicy, error)

func GetSshAccount added in v0.7.0

func GetSshAccount(opts *SshCommonOptions, flags *SshCommonFlags) (accounts.IAccount, error)

func PromptForDotNetConfig added in v0.7.0

func PromptForDotNetConfig(opts *SshCommonOptions, flags *SshCommonFlags, entityType string) error

func PromptForProxy

func PromptForProxy(opts *CreateTargetProxyOptions, flags *CreateTargetProxyFlags, description string) error

func PromptForSshAccount added in v0.7.0

func PromptForSshAccount(opts *SshCommonOptions, flags *SshCommonFlags) error

func PromptForSshEndpoint added in v0.7.0

func PromptForSshEndpoint(opts *SshCommonOptions, flags *SshCommonFlags, entityType string) error

func RegisterCreateTargetMachinePolicyFlags

func RegisterCreateTargetMachinePolicyFlags(cmd *cobra.Command, machinePolicyFlags *CreateTargetMachinePolicyFlags)

func RegisterCreateTargetProxyFlags

func RegisterCreateTargetProxyFlags(cmd *cobra.Command, proxyFlags *CreateTargetProxyFlags, description string)

func RegisterSshCommonFlags added in v0.7.0

func RegisterSshCommonFlags(cmd *cobra.Command, flags *SshCommonFlags, entityType string)

func RegisterWebFlag

func RegisterWebFlag(cmd *cobra.Command, flags *WebFlags)

Types

type CreateTargetMachinePolicyFlags

type CreateTargetMachinePolicyFlags struct {
	MachinePolicy *flag.Flag[string]
}

func NewCreateTargetMachinePolicyFlags

func NewCreateTargetMachinePolicyFlags() *CreateTargetMachinePolicyFlags

type CreateTargetMachinePolicyOptions

type CreateTargetMachinePolicyOptions struct {
	*cmd.Dependencies
	GetAllMachinePoliciesCallback
}

func NewCreateTargetMachinePolicyOptions

func NewCreateTargetMachinePolicyOptions(dependencies *cmd.Dependencies) *CreateTargetMachinePolicyOptions

type CreateTargetProxyFlags

type CreateTargetProxyFlags struct {
	Proxy *flag.Flag[string]
}

func NewCreateTargetProxyFlags

func NewCreateTargetProxyFlags() *CreateTargetProxyFlags

type CreateTargetProxyOptions

type CreateTargetProxyOptions struct {
	*cmd.Dependencies
	GetAllProxiesCallback
}

func NewCreateTargetProxyOptions

func NewCreateTargetProxyOptions(dependencies *cmd.Dependencies) *CreateTargetProxyOptions

type GetAllAccountsForSshMachine added in v0.7.0

type GetAllAccountsForSshMachine func() ([]accounts.IAccount, error)

type GetAllMachinePoliciesCallback

type GetAllMachinePoliciesCallback func() ([]*machines.MachinePolicy, error)

type GetAllProxiesCallback

type GetAllProxiesCallback func() ([]*proxies.Proxy, error)

type SshCommonFlags added in v0.7.0

type SshCommonFlags struct {
	Fingerprint *flag.Flag[string]
	HostName    *flag.Flag[string]
	Port        *flag.Flag[int]
	Account     *flag.Flag[string]
	Runtime     *flag.Flag[string]
	Platform    *flag.Flag[string]
}

func NewSshCommonFlags added in v0.7.0

func NewSshCommonFlags() *SshCommonFlags

type SshCommonOptions added in v0.7.0

type SshCommonOptions struct {
	*cmd.Dependencies
	GetAllAccountsForSshMachine
}

func NewSshCommonOpts added in v0.7.0

func NewSshCommonOpts(dependencies *cmd.Dependencies) *SshCommonOptions

type WebFlags

type WebFlags struct {
	Web *flag.Flag[bool]
}

func NewWebFlags

func NewWebFlags() *WebFlags

Jump to

Keyboard shortcuts

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