provider

package
v0.0.9 Latest Latest
Warning

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

Go to latest
Published: Mar 1, 2024 License: MPL-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Ansible

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

func (*Ansible) Run

func (s *Ansible) Run(ctx context.Context, providerConfig interface{}, inventory *ansible.Inventory) error

type AnsibleConfig

type AnsibleConfig struct {
	SudoUser   string            `yaml:"sudo_user"`
	GlobalVars map[string]string `yaml:"global_vars"`
	Playbooks  []Playbook        `yaml:"playbooks"`
}

type Playbook

type Playbook struct {
	Name string            `yaml:"file"`
	Vars map[string]string `yaml:"vars"`
}

type Runner

type Runner interface {
	RunAll(ctx context.Context, cnf *conf.Config, inventory *ansible.Inventory) error
}

func DefaultRunner

func DefaultRunner() Runner

type Service

type Service interface {
	// Run runs the provider, takes context, global config, provider config and inventory.
	// provider config is the interface argument because it is specific to the provider
	Run(context.Context, interface{}, *ansible.Inventory) error
}

Jump to

Keyboard shortcuts

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