ansible

package
v0.15.2 Latest Latest
Warning

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

Go to latest
Published: Feb 13, 2020 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Overview

Copyright 2019 The Operator-SDK Authors

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Index

Constants

View Source
const (
	RolesDir               = "roles"
	MoleculeDir            = "molecule"
	MoleculeTestClusterDir = MoleculeDir + filePathSep + "test-cluster"
	MoleculeDefaultDir     = MoleculeDir + filePathSep + "default"
	MoleculeTestLocalDir   = MoleculeDir + filePathSep + "test-local"
)
View Source
const BuildDockerfileFile = "Dockerfile"
View Source
const BuildTestFrameworkAnsibleTestScriptFile = "ansible-test.sh"
View Source
const BuildTestFrameworkDockerfileFile = "Dockerfile"
View Source
const DeployOperatorFile = "operator.yaml"
View Source
const GoModFile = "go.mod"
View Source
const MoleculeDefaultAssertsFile = "asserts.yml"
View Source
const MoleculeDefaultMoleculeFile = "molecule.yml"
View Source
const MoleculeDefaultPlaybookFile = "playbook.yml"
View Source
const MoleculeDefaultPrepareFile = "prepare.yml"
View Source
const MoleculeTestClusterMoleculeFile = "molecule.yml"
View Source
const MoleculeTestClusterPlaybookFile = "playbook.yml"
View Source
const MoleculeTestLocalMoleculeFile = "molecule.yml"
View Source
const MoleculeTestLocalPlaybookFile = "playbook.yml"
View Source
const MoleculeTestLocalPrepareFile = "prepare.yml"
View Source
const PlaybookYamlFile = "playbook.yml"
View Source
const RolesDefaultsMainFile = "defaults" + filePathSep + "main.yml"
View Source
const RolesFilesDir = "files" + filePathSep + ".placeholder"
View Source
const RolesHandlersMainFile = "handlers" + filePathSep + "main.yml"
View Source
const RolesMetaMainFile = "meta" + filePathSep + "main.yml"
View Source
const RolesReadmeFile = "README.md"
View Source
const RolesTasksMainFile = "tasks" + filePathSep + "main.yml"
View Source
const RolesTemplatesDir = "templates" + filePathSep + ".placeholder"
View Source
const RolesVarsMainFile = "vars" + filePathSep + "main.yml"
View Source
const TravisFile = ".travis.yml"
View Source
const WatchesFile = "watches.yaml"

Variables

View Source
var AnsibleDelims = [2]string{"[[", "]]"}

AnsibleDelims is a slice of two strings representing the left and right delimiters for ansible templates. Arrays can't be constants but this should be a constant.

Functions

func PrintGoMod

func PrintGoMod() error

Types

type AoLogs

type AoLogs struct {
	StaticInput
}

DockerfileHybrid - Dockerfile for a hybrid operator

func (*AoLogs) GetInput

func (a *AoLogs) GetInput() (input.Input, error)

GetInput - gets the input

type BuildDockerfile

type BuildDockerfile struct {
	input.Input
	RolesDir         string
	ImageTag         string
	GeneratePlaybook bool
}

func (*BuildDockerfile) GetInput

func (b *BuildDockerfile) GetInput() (input.Input, error)

GetInput - gets the input

type BuildTestFrameworkAnsibleTestScript

type BuildTestFrameworkAnsibleTestScript struct {
	StaticInput
}

func (*BuildTestFrameworkAnsibleTestScript) GetInput

GetInput - gets the input

type BuildTestFrameworkDockerfile

type BuildTestFrameworkDockerfile struct {
	StaticInput
}

func (*BuildTestFrameworkDockerfile) GetInput

func (b *BuildTestFrameworkDockerfile) GetInput() (input.Input, error)

GetInput - gets the input

type DeployOperator

type DeployOperator struct {
	input.Input
}

func (*DeployOperator) GetInput

func (d *DeployOperator) GetInput() (input.Input, error)

GetInput - gets the input

type DockerfileHybrid

type DockerfileHybrid struct {
	input.Input

	// Playbook - if true, include a COPY statement for playbook.yml
	Playbook bool

	// Roles - if true, include a COPY statement for the roles directory
	Roles bool

	// Watches - if true, include a COPY statement for watches.yaml
	Watches bool
}

DockerfileHybrid - Dockerfile for a hybrid operator

func (*DockerfileHybrid) GetInput

func (d *DockerfileHybrid) GetInput() (input.Input, error)

GetInput - gets the input

type Entrypoint

type Entrypoint struct {
	StaticInput
}

Entrypoint - entrypoint script

func (*Entrypoint) GetInput

func (e *Entrypoint) GetInput() (input.Input, error)

type GoMod

type GoMod struct {
	input.Input
}

GoMod - the go.mod file for an Ansible hybrid operator.

func (*GoMod) GetInput

func (s *GoMod) GetInput() (input.Input, error)

type Main

type Main struct {
	StaticInput
}

Main - main source file for ansible operator

func (*Main) GetInput

func (m *Main) GetInput() (input.Input, error)

type MoleculeDefaultAsserts

type MoleculeDefaultAsserts struct {
	input.Input
}

func (*MoleculeDefaultAsserts) GetInput

func (m *MoleculeDefaultAsserts) GetInput() (input.Input, error)

GetInput - gets the input

type MoleculeDefaultMolecule

type MoleculeDefaultMolecule struct {
	StaticInput
}

func (*MoleculeDefaultMolecule) GetInput

func (m *MoleculeDefaultMolecule) GetInput() (input.Input, error)

GetInput - gets the input

type MoleculeDefaultPlaybook

type MoleculeDefaultPlaybook struct {
	input.Input
	GeneratePlaybook bool
	Resource         scaffold.Resource
}

func (*MoleculeDefaultPlaybook) GetInput

func (m *MoleculeDefaultPlaybook) GetInput() (input.Input, error)

GetInput - gets the input

type MoleculeDefaultPrepare

type MoleculeDefaultPrepare struct {
	input.Input
}

func (*MoleculeDefaultPrepare) GetInput

func (m *MoleculeDefaultPrepare) GetInput() (input.Input, error)

GetInput - gets the input

type MoleculeTestClusterMolecule

type MoleculeTestClusterMolecule struct {
	StaticInput
}

func (*MoleculeTestClusterMolecule) GetInput

func (m *MoleculeTestClusterMolecule) GetInput() (input.Input, error)

GetInput - gets the input

type MoleculeTestClusterPlaybook

type MoleculeTestClusterPlaybook struct {
	input.Input
	Resource scaffold.Resource
}

func (*MoleculeTestClusterPlaybook) GetInput

func (m *MoleculeTestClusterPlaybook) GetInput() (input.Input, error)

GetInput - gets the input

type MoleculeTestLocalMolecule

type MoleculeTestLocalMolecule struct {
	StaticInput
}

func (*MoleculeTestLocalMolecule) GetInput

func (m *MoleculeTestLocalMolecule) GetInput() (input.Input, error)

GetInput - gets the input

type MoleculeTestLocalPlaybook

type MoleculeTestLocalPlaybook struct {
	input.Input
	Resource scaffold.Resource
}

func (*MoleculeTestLocalPlaybook) GetInput

func (m *MoleculeTestLocalPlaybook) GetInput() (input.Input, error)

GetInput - gets the input

type MoleculeTestLocalPrepare

type MoleculeTestLocalPrepare struct {
	input.Input
	Resource scaffold.Resource
}

func (*MoleculeTestLocalPrepare) GetInput

func (m *MoleculeTestLocalPrepare) GetInput() (input.Input, error)

GetInput - gets the input

type Playbook

type Playbook struct {
	input.Input
	Resource scaffold.Resource
}

Playbook - the playbook tmpl wrapper

func (*Playbook) GetInput

func (p *Playbook) GetInput() (input.Input, error)

GetInput - gets the input

type RolesDefaultsMain

type RolesDefaultsMain struct {
	input.Input
	Resource scaffold.Resource
}

func (*RolesDefaultsMain) GetInput

func (r *RolesDefaultsMain) GetInput() (input.Input, error)

GetInput - gets the input

type RolesFiles

type RolesFiles struct {
	StaticInput
	Resource scaffold.Resource
}

func (*RolesFiles) GetInput

func (r *RolesFiles) GetInput() (input.Input, error)

GetInput - gets the input

type RolesHandlersMain

type RolesHandlersMain struct {
	input.Input
	Resource scaffold.Resource
}

func (*RolesHandlersMain) GetInput

func (r *RolesHandlersMain) GetInput() (input.Input, error)

GetInput - gets the input

type RolesMetaMain

type RolesMetaMain struct {
	StaticInput
	Resource scaffold.Resource
}

func (*RolesMetaMain) GetInput

func (r *RolesMetaMain) GetInput() (input.Input, error)

GetInput - gets the input

type RolesReadme

type RolesReadme struct {
	StaticInput
	Resource scaffold.Resource
}

func (*RolesReadme) GetInput

func (r *RolesReadme) GetInput() (input.Input, error)

GetInput - gets the input

type RolesTasksMain

type RolesTasksMain struct {
	input.Input
	Resource scaffold.Resource
}

func (*RolesTasksMain) GetInput

func (r *RolesTasksMain) GetInput() (input.Input, error)

GetInput - gets the input

type RolesTemplates

type RolesTemplates struct {
	StaticInput
	Resource scaffold.Resource
}

func (*RolesTemplates) GetInput

func (r *RolesTemplates) GetInput() (input.Input, error)

GetInput - gets the input

type RolesVarsMain

type RolesVarsMain struct {
	input.Input
	Resource scaffold.Resource
}

func (*RolesVarsMain) GetInput

func (r *RolesVarsMain) GetInput() (input.Input, error)

GetInput - gets the input

type StaticInput

type StaticInput struct {
	input.Input
}

StaticInput is the input for scaffolding a static file with no parameters

func (*StaticInput) CustomRender

func (s *StaticInput) CustomRender() ([]byte, error)

CustomRender return the template body unmodified

func (StaticInput) SetFS

func (s StaticInput) SetFS(_ afero.Fs)

type Travis

type Travis struct {
	StaticInput
}

func (*Travis) GetInput

func (t *Travis) GetInput() (input.Input, error)

GetInput - gets the input

type UserSetup

type UserSetup struct {
	StaticInput
}

UserSetup - userSetup script

func (*UserSetup) GetInput

func (u *UserSetup) GetInput() (input.Input, error)

type Watches

type Watches struct {
	input.Input
	GeneratePlaybook bool
	RolesDir         string
	Resource         scaffold.Resource
}

func (*Watches) GetInput

func (w *Watches) GetInput() (input.Input, error)

GetInput - gets the input

Jump to

Keyboard shortcuts

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