ssh

package
v1.21.42 Latest Latest
Warning

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

Go to latest
Published: Dec 24, 2025 License: BSD-3-Clause Imports: 25 Imported by: 0

Documentation

Overview

Copyright (C) 2022-2025, Lux Industries Inc. All rights reserved. See the file LICENSE for licensing terms.

Copyright (C) 2022-2025, Lux Industries Inc. All rights reserved. See the file LICENSE for licensing terms.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ComposeSSHSetupWarpRelayer

func ComposeSSHSetupWarpRelayer(host *models.Host, relayerVersion string) error

ComposeSSHSetupWarpRelayer used docker compose to setup AWM Relayer

func PostOverSSH

func PostOverSSH(host *models.Host, path string, requestBody string) ([]byte, error)

func RunOverSSH

func RunOverSSH(
	scriptDesc string,
	host *models.Host,
	timeout time.Duration,
	scriptPath string,
	templateVars scriptInputs,
) error

RunOverSSH runs provided script path over ssh. This script can be template as it will be rendered using scriptInputs vars

func RunSSHBuildLoadTestCode

func RunSSHBuildLoadTestCode(host *models.Host, loadTestRepo, loadTestPath, loadTestGitCommit, repoDirName, loadTestBranch string, checkoutCommit bool) error

func RunSSHBuildLoadTestDependencies

func RunSSHBuildLoadTestDependencies(host *models.Host) error

func RunSSHCheckBootstrapped

func RunSSHCheckBootstrapped(host *models.Host) ([]byte, error)

RunSSHCheckBootstrapped checks if node is bootstrapped to primary network

func RunSSHCheckHealthy

func RunSSHCheckHealthy(host *models.Host) ([]byte, error)

RunSSHCheckHealthy checks if node is healthy

func RunSSHCheckLuxdVersion

func RunSSHCheckLuxdVersion(host *models.Host) ([]byte, error)

RunSSHCheckLuxdVersion checks node luxd version

func RunSSHCopyMonitoringDashboards

func RunSSHCopyMonitoringDashboards(host *models.Host, monitoringDashboardPath string) error

func RunSSHCopyYAMLFile

func RunSSHCopyYAMLFile(host *models.Host, yamlFilePath string) error

func RunSSHCreatePlugin

func RunSSHCreatePlugin(host *models.Host, sc models.Sidecar) error

RunSSHCreatePlugin runs script to create plugin

func RunSSHDownloadFile

func RunSSHDownloadFile(host *models.Host, filePath string, localFilePath string) error

RunSSHDownloadFile downloads specified file from the specified host

func RunSSHDownloadNodePrometheusConfig

func RunSSHDownloadNodePrometheusConfig(host *models.Host, nodeInstanceDirPath string) error

func RunSSHGetNewEVMRelease added in v1.21.40

func RunSSHGetNewEVMRelease(host *models.Host, evmReleaseURL, evmArchive string) error

RunSSHGetNewEVMRelease runs script to download new subnet evm

func RunSSHGetNodeID

func RunSSHGetNodeID(host *models.Host) ([]byte, error)

RunSSHGetNodeID reads nodeID from luxd

func RunSSHRenderLuxNodeConfig

func RunSSHRenderLuxNodeConfig(
	app *application.Lux,
	host *models.Host,
	network models.Network,
	trackSubnets []string,
	isAPIHost bool,
) error

RunSSHRenderLuxNodeConfig renders lux node config to a remote host via SSH.

func RunSSHRenderLuxdAliasConfigFile

func RunSSHRenderLuxdAliasConfigFile(
	host *models.Host,
	blockchainID string,
	subnetAliases []string,
) error

RunSSHRenderLuxdAliasConfigFile renders lux alias config to a remote host via SSH.

func RunSSHRestartNode

func RunSSHRestartNode(host *models.Host) error

RunSSHRestartNode runs script to restart luxd

func RunSSHRunLoadTest

func RunSSHRunLoadTest(host *models.Host, loadTestCommand, loadTestName string) error

func RunSSHSetupDevNet

func RunSSHSetupDevNet(host *models.Host, nodeInstanceDirPath string) error

RunSSHSetupDevNet runs script to setup devnet

func RunSSHSetupDockerService

func RunSSHSetupDockerService(host *models.Host) error

RunSSHSetupDockerService runs script to setup docker compose service for CLI

func RunSSHSetupLokiConfig

func RunSSHSetupLokiConfig(host *models.Host, port int) error

func RunSSHSetupMonitoringFolders

func RunSSHSetupMonitoringFolders(host *models.Host) error

func RunSSHSetupNode

func RunSSHSetupNode(host *models.Host, configPath string) error

RunSSHSetupNode runs script to setup node

func RunSSHSetupPrometheusConfig

func RunSSHSetupPrometheusConfig(host *models.Host, luxdPorts, machinePorts, loadTestPorts []string) error

func RunSSHSetupPromtailConfig

func RunSSHSetupPromtailConfig(host *models.Host, lokiIP string, lokiPort int, cloudID string, nodeID string, chainID string) error

func RunSSHStartNode

func RunSSHStartNode(host *models.Host) error

RunSSHStartNode runs script to start luxd

func RunSSHStartWarpRelayerService

func RunSSHStartWarpRelayerService(host *models.Host) error

RunSSHStartWarpRelayerService runs script to start an AWM Relayer Service

func RunSSHStopNode

func RunSSHStopNode(host *models.Host) error

RunSSHStopNode runs script to stop luxd

func RunSSHStopWarpRelayerService

func RunSSHStopWarpRelayerService(host *models.Host) error

RunSSHStopWarpRelayerService runs script to start an AWM Relayer Service

func RunSSHSubnetSyncStatus

func RunSSHSubnetSyncStatus(host *models.Host, blockchainID string) ([]byte, error)

SubnetSyncStatus checks if node is synced to subnet

func RunSSHSyncSubnetData

func RunSSHSyncSubnetData(app *application.Lux, host *models.Host, network models.Network, subnetName string) error

RunSSHSyncSubnetData syncs subnet data required

func RunSSHUpdateMonitoringDashboards

func RunSSHUpdateMonitoringDashboards(host *models.Host, monitoringDashboardPath, customGrafanaDashboardPath, chainID string) error

func RunSSHUpgradeLuxgo

func RunSSHUpgradeLuxgo(host *models.Host, luxdVersion string) error

RunSSHUpgradeLuxgo runs script to upgrade luxd

func RunSSHUploadNodeWarpRelayerConfig

func RunSSHUploadNodeWarpRelayerConfig(host *models.Host, nodeInstanceDirPath string) error

func RunSSHUploadStakingFiles

func RunSSHUploadStakingFiles(host *models.Host, nodeInstanceDirPath string) error

RunSSHUploadStakingFiles uploads staking files to a remote host via SSH.

func RunSSHUpsizeRootDisk

func RunSSHUpsizeRootDisk(host *models.Host) error

func RunSSHWhitelistPubKey

func RunSSHWhitelistPubKey(host *models.Host, sshPubKey string) error

RunSSHWhitelistPubKey downloads the authorized_keys file from the specified host, appends the provided sshPubKey to it, and uploads the file back to the host.

func StreamOverSSH

func StreamOverSSH(
	scriptDesc string,
	host *models.Host,
	timeout time.Duration,
	scriptPath string,
	templateVars scriptInputs,
) error

StreamOverSSH runs provided script path over ssh. This script can be template as it will be rendered using scriptInputs vars

Types

type HostInstaller

type HostInstaller struct {
	Host *models.Host
}

func NewHostInstaller

func NewHostInstaller(host *models.Host) *HostInstaller

func (*HostInstaller) GetArch

func (h *HostInstaller) GetArch() (string, string)

Jump to

Keyboard shortcuts

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