Dagger
Search

ssh

Run a command on a remote machine using SSH and return the result

Installation

dagger install github.com/samalba/dagger-modules/ssh@68a7e64f5cba76bd4cadc886fec27c1e60b80480

Entrypoint

Return Type
Ssh
Example
func (m *myModule) example() *Ssh  {
	return dag.
			Ssh()
}
@function
def example() -> dag.Ssh:
	return (
		dag.ssh()
	)
@func()
example(): Ssh {
	return dag
		.ssh()
}

Types

Ssh 🔗

baseCtr() 🔗

Return Type
Container !
Example
dagger -m github.com/samalba/dagger-modules/ssh@68a7e64f5cba76bd4cadc886fec27c1e60b80480 call \
 base-ctr
func (m *myModule) example() *Container  {
	return dag.
			Ssh().
			BaseCtr()
}
@function
def example() -> dagger.Container:
	return (
		dag.ssh()
		.base_ctr()
	)
@func()
example(): Container {
	return dag
		.ssh()
		.baseCtr()
}

destination() 🔗

Return Type
String !
Example
dagger -m github.com/samalba/dagger-modules/ssh@68a7e64f5cba76bd4cadc886fec27c1e60b80480 call \
 destination
func (m *myModule) example(ctx context.Context) string  {
	return dag.
			Ssh().
			Destination(ctx)
}
@function
async def example() -> str:
	return await (
		dag.ssh()
		.destination()
	)
@func()
async example(): Promise<string> {
	return dag
		.ssh()
		.destination()
}

opts() 🔗

Return Type
[Sshopts ! ] !
Example
Function Ssh.opts is not accessible from the ssh module
func (m *myModule) example() []*SshSshopts  {
	return dag.
			Ssh().
			Opts()
}
@function
def example() -> List[dag.SshSshopts]:
	return (
		dag.ssh()
		.opts()
	)
@func()
example(): SshSshopts[] {
	return dag
		.ssh()
		.opts()
}

command() 🔗

example usage: “dagger call –destination USER@HOST –identity-file file:${HOME}/.ssh/id_ed25519 command –args whoami stdout”

Return Type
Container !
Arguments
NameTypeDefault ValueDescription
args[String ! ] !-No description provided
Example
dagger -m github.com/samalba/dagger-modules/ssh@68a7e64f5cba76bd4cadc886fec27c1e60b80480 call \
 command --args string1 --args string2
func (m *myModule) example(args []string) *Container  {
	return dag.
			Ssh().
			Command(args)
}
@function
def example(args: List[str]) -> dagger.Container:
	return (
		dag.ssh()
		.command(args)
	)
@func()
example(args: string[]): Container {
	return dag
		.ssh()
		.command(args)
}

Sshopts 🔗

identityFile() 🔗

Return Type
Secret !
Example
Function SshSshopts.identityFile is not accessible from the ssh module
Function SshSshopts.identityFile is not accessible from the ssh module
Function SshSshopts.identityFile is not accessible from the ssh module
Function SshSshopts.identityFile is not accessible from the ssh module

port() 🔗

Return Type
Integer !
Example
Function SshSshopts.port is not accessible from the ssh module
Function SshSshopts.port is not accessible from the ssh module
Function SshSshopts.port is not accessible from the ssh module
Function SshSshopts.port is not accessible from the ssh module

login() 🔗

Return Type
String !
Example
Function SshSshopts.login is not accessible from the ssh module
Function SshSshopts.login is not accessible from the ssh module
Function SshSshopts.login is not accessible from the ssh module
Function SshSshopts.login is not accessible from the ssh module