ansible

package module
v0.0.0-...-4dcef78 Latest Latest
Warning

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

Go to latest
Published: Aug 2, 2023 License: Unlicense Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ExitJSON

func ExitJSON(r Response)

func FailJSON

func FailJSON(r Response)

func ReturnResponse

func ReturnResponse(r Response)

func RunCmd

func RunCmd(w io.Writer, cmd string, b *strings.Builder) (string, error)

func StripPrompt

func StripPrompt(s string) string

Types

type AnsibleDevice

type AnsibleDevice struct {
	User            string
	Password        string
	Host            string
	AnsibleResponse Response
	Cmd             string
}

type Cmd

type Cmd struct {
	Command interface{} `json:"command"`
}

type Provider

type Provider struct {
	Provider struct {
		Username string `json:"username"`
		Password string `json:"password"`
		Host     string `json:"host"`
	} `json:"provider"`
}

type Response

type Response struct {
	Msg    string `json:"msg"`
	Stdout string `json:"stdout"`
	Failed bool   `json:"failed"`
}

Jump to

Keyboard shortcuts

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