provisioner

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Oct 16, 2024 License: GPL-3.0 Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AnsibleLocalProvisioner

type AnsibleLocalProvisioner struct {
	Name         string
	Command      string
	Args         []string
	ExtraArgs    []string
	SkipTags     []string
	Tags         []string
	EnvVars      map[string]string
	Playbook     string
	Dependencies Dependencies
}

func (AnsibleLocalProvisioner) GetCommand

func (a AnsibleLocalProvisioner) GetCommand() (map[string]string, string, []string)

func (AnsibleLocalProvisioner) GetDependencies added in v0.2.0

func (a AnsibleLocalProvisioner) GetDependencies() Dependencies

func (AnsibleLocalProvisioner) GetInstallDependenciesCommand added in v0.2.0

func (a AnsibleLocalProvisioner) GetInstallDependenciesCommand() (map[string]string, string, []string)

func (AnsibleLocalProvisioner) String

func (a AnsibleLocalProvisioner) String() string

func (AnsibleLocalProvisioner) WithExtraArgs

func (a AnsibleLocalProvisioner) WithExtraArgs(args []string) Provisioner

func (AnsibleLocalProvisioner) WithGalaxyDependencies added in v0.2.0

func (a AnsibleLocalProvisioner) WithGalaxyDependencies(dependencies []string) Provisioner

func (AnsibleLocalProvisioner) WithLocalDependencies added in v0.2.0

func (a AnsibleLocalProvisioner) WithLocalDependencies(dependencies []string) Provisioner

func (AnsibleLocalProvisioner) WithPlaybook

func (a AnsibleLocalProvisioner) WithPlaybook(playbook string) Provisioner

func (AnsibleLocalProvisioner) WithSkipTags

func (a AnsibleLocalProvisioner) WithSkipTags(tags []string) Provisioner

func (AnsibleLocalProvisioner) WithTags

func (a AnsibleLocalProvisioner) WithTags(tags []string) Provisioner

type Config

type Config struct {
	Name      string            `mapstructure:"name"`
	Command   string            `mapstructure:"command"`
	Args      []string          `mapstructure:"args"`
	ExtraArgs []string          `mapstructure:"extra_args"`
	EnvVars   map[string]string `mapstructure:"env"`
	Playbook  string            `mapstructure:"playbook"`
}

type Dependencies added in v0.2.0

type Dependencies struct {
	Collections []string
	LocalRoles  []string
	GalaxyRoles []string
}

type Provisioner

type Provisioner interface {
	GetInstallDependenciesCommand() (map[string]string, string, []string)
	GetCommand() (map[string]string, string, []string)
	WithSkipTags([]string) Provisioner
	WithTags([]string) Provisioner
	WithPlaybook(string) Provisioner
	GetDependencies() Dependencies
	WithLocalDependencies([]string) Provisioner
	WithGalaxyDependencies([]string) Provisioner
	String() string
}

func NewProvisioner

func NewProvisioner(config Config) (Provisioner, error)

type RoleMetadata added in v0.2.0

type RoleMetadata struct {
	Collections  []string `yaml:"collections"`
	Dependencies []struct {
		Role string `yaml:"role"`
	} `yaml:"dependencies"`
}

func GetRoleMetadata added in v0.2.0

func GetRoleMetadata() (*RoleMetadata, error)

GetRoleMetadata parses the role meta/main.yml file and returns a RoleMetadata struct

func (*RoleMetadata) GalaxyDependencies added in v0.2.0

func (md *RoleMetadata) GalaxyDependencies() []string

func (*RoleMetadata) LocalDependencies added in v0.2.0

func (md *RoleMetadata) LocalDependencies() []string

Jump to

Keyboard shortcuts

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