config

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Apr 12, 2026 License: AGPL-3.0 Imports: 0 Imported by: 0

Documentation

Overview

Package config provides configuration types for SSH-based automation.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	// SSH connection settings
	SSHHost  string
	SSHPort  string
	SSHLogin string
	SSHKey   string

	// User settings
	RootUser    string
	NonRootUser string

	// Database settings (when applicable)
	DBPort         string
	DBRootPassword string

	// Extra arguments passed via command line
	Args map[string]string
}

Config holds all configuration variables for remote server operations.

func (Config) GetArg

func (c Config) GetArg(key string) string

GetArg retrieves an argument from the Args map. Returns empty string if not found.

func (Config) GetArgOr

func (c Config) GetArgOr(key, defaultValue string) string

GetArgOr retrieves an argument from the Args map with a default value.

func (Config) SSHAddr

func (c Config) SSHAddr() string

SSHAddr returns the full SSH address as host:port. Defaults to port 22 if SSHPort is not set.

Jump to

Keyboard shortcuts

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