Documentation ¶
Index ¶
- func BuildVerify() error
- func Execute(steps []Step) error
- func Generate() error
- func GetDependencies(dependencies []string) func() error
- func ModTidy() error
- func ModVendor() error
- func TerraformInit() error
- func TerraformInitFast() error
- func TerraformRequire() error
- type Step
- func Backup(path string) Step
- func Build(pkg string, target string, goEnvs ...string) Step
- func Chdir(path string) Step
- func Delete(path string) Step
- func InitProjectPath(path string, finalModulePath *string) Step
- func ModInit(finalModulePath *string) Step
- func PackageZip(source string, target string) Step
- func PackageZipRename(source string, target string, newSourceName string) Step
- func PluginInstall(pkg, version, target string) Step
- func RenderTemplate(fs embed.FS, source string, target string, variables interface{}) Step
- func RenderTemplates(fs embed.FS, prefix string, variables interface{}) Step
- func TerraformApply(workspace string, args ...string) Step
- func TerraformDestroy(workspace string, args ...string) Step
- func TerraformNewWorkspace(workspace string) Step
- func TerraformPlan(workspace string, args ...string) Step
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func BuildVerify ¶
func BuildVerify() error
BuildVerify creates a step that ensures the validity of the generated project.
func GetDependencies ¶
GetDependencies creates a step that downloads the specified dependencies.
func TerraformInit ¶
func TerraformInit() error
TerraformInit creates a step that runs terraform init with the upgrade flag.
func TerraformInitFast ¶ added in v0.16.1
func TerraformInitFast() error
TerraformInitFast creates a step that runs terraform init without the upgrade flag.
func TerraformRequire ¶
func TerraformRequire() error
TerraformRequire creates a step that ensures that terraform is installed.
Types ¶
type Step ¶
type Step func() error
Step defines the function interface for an action to be performed.
func InitProjectPath ¶
InitProjectPath creates a step that gathers information about the project path.
func PackageZip ¶
PackageZip creates a step that packages the source into a zip file.
func PackageZipRename ¶ added in v0.6.0
PackageZipRename packages source file into target zip, the resulting zip contains the source file but named with newSourceName
func PluginInstall ¶
PluginInstall creates a step that installs the provided plugin.
func RenderTemplate ¶ added in v0.13.0
RenderTemplate creates a step that renders the provided template.
func RenderTemplates ¶
RenderTemplates creates a step that renders the provided templates.
func TerraformApply ¶
TerraformApply creates a step that runs terraform apply with the provided arguments.
func TerraformDestroy ¶
TerraformDestroy creates a step that runs terraform destroy with the provided arguments.
func TerraformNewWorkspace ¶ added in v0.12.0
TerraformNewWorkspace creates a step that initializes a new terraform workspace if it does not yet exist.
func TerraformPlan ¶ added in v0.15.0
TerraformPlan creates a step that runs terraform plan with the provided arguments.
Source Files ¶
- backup.go
- build.go
- buildverify.go
- chdir.go
- delete.go
- generate.go
- getdependencies.go
- initprojectpath.go
- modinit.go
- modtidy.go
- modvendor.go
- packagezip.go
- packageziprename.go
- plugininstall.go
- rendertemplates.go
- runcommand.go
- steps.go
- terraformapply.go
- terraformdestroy.go
- terraforminit.go
- terraformnewworkspace.go
- terraformplan.go
- terraformrequire.go