noninteractivecommands

package
v0.0.0-...-f6ab670 Latest Latest
Warning

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

Go to latest
Published: Nov 19, 2024 License: Apache-2.0 Imports: 10 Imported by: 1

Documentation

Overview

Package noninteractivecommands implements session shell sessionPlugin with non-interactive command execution.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewPlugin

func NewPlugin(context context.T) (sessionplugin.ISessionPlugin, error)

NewPlugin returns a new instance of the InteractiveCommands Plugin

Types

type NonInteractiveCommandsPlugin

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

NonInteractiveCommandsPlugin is the type for the sessionPlugin.

func (*NonInteractiveCommandsPlugin) Execute

Execute executes command as passed in from document parameter via cmd.Exec. It reads message from cmd.stdout and writes to data channel.

func (*NonInteractiveCommandsPlugin) GetPluginParameters

func (p *NonInteractiveCommandsPlugin) GetPluginParameters(parameters interface{}) interface{}

Returns parameters required for CLI/console to start session

func (*NonInteractiveCommandsPlugin) InputStreamMessageHandler

func (p *NonInteractiveCommandsPlugin) InputStreamMessageHandler(log log.T, streamDataMessage mgsContracts.AgentMessage) error

InputStreamMessageHandler passes payload byte stream to command execution process

func (*NonInteractiveCommandsPlugin) RequireHandshake

func (p *NonInteractiveCommandsPlugin) RequireHandshake() bool

Override as NonInteractiveCommandsPlugin plugin requires handshake to establish session

Jump to

Keyboard shortcuts

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