- Notifications
You must be signed in to change notification settings - Fork17
Utility provider that exposes the cloudinit_config data source which renders a multipart MIME configuration for use with cloud-init (previously available as the template_cloudinit_config resource in the template provider)
License
hashicorp/terraform-provider-cloudinit
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
The cloud-init provider supports renderingcloud-init configurations in aMIME multi-part file.
This provider is intended to replace thetemplate provider. General templating can now be achieved through the
templatefile
function, without creating a separate data resource.This provider exposes thecloudinit_config
data source and resource, previously available as thetemplate_cloudinit_config
in the template provider.
Official documentation on how to use this provider can be found on theTerraform Registry.In case of specific questions or discussions, please use theHashiCorpTerraform Providers Discuss forums,in accordance with HashiCorpCommunity Guidelines.
We also provide:
- Support page for help when using the provider
- Contributing guidelines in case you want to help this project
- Design documentation to understand the scope and maintenance decisions
The remainder of this document will focus on the development aspects of the provider.
- Terraform
- Go (1.23)
- GNU Make
- golangci-lint (optional)
git clone
this repository andcd
into its directorymake
will trigger the Golang build
The providedGNUmakefile
defines additional commands generally useful during development,like for running tests, generating documentation, code formatting and linting.Taking a look at it's content is recommended.
In order to test the provider, you can run
make test
to run provider testsmake testacc
to run provider acceptance tests
It's important to note that acceptance tests (testacc
) will actually spawnterraform
and the provider. Read more about they work on theofficial page.
This provider usesterraform-plugin-docsto generate documentation and store it in thedocs/
directory.Once a release is cut, the Terraform Registry will download the documentation fromdocs/
and associate it with the release version. Read more about how this works on theofficial page.
Usemake generate
to ensure the documentation is regenerated with any changes.
Ifrunning tests and acceptance tests isn't enough, it's possible to set up a local terraform configurationto use a development builds of the provider. This can be achieved by leveraging the Terraform CLIconfiguration file development overrides.
First, usemake install
to place a fresh development build of the provider in your${GOBIN}
(defaults to${GOPATH}/bin
or${HOME}/go/bin
if${GOPATH}
is not set). Repeatthis every time you make changes to the provider locally.
Then, setup your environment followingthese instructionsto make your local terraform use your local build.
This project usesGitHub Actions to realize its CI.
Sometimes it might be helpful to locally reproduce the behaviour of those actions,and for this we useact. Once installed, you cansimulate the actions executedwhen opening a PR with:
# List of workflows for the 'pull_request' action$ act -l pull_request# Execute the workflows associated with the `pull_request' action$ act pull_request
The releasable builds are generated from thebuild GH workflow and the release/promotion processis completed via internal HashiCorp deployment tooling. Prior to release, the changelog should be updated inmain
withthe changie tool, example:
changie batch 2.3.7&& changie merge
About
Utility provider that exposes the cloudinit_config data source which renders a multipart MIME configuration for use with cloud-init (previously available as the template_cloudinit_config resource in the template provider)
Topics
Resources
License
Code of conduct
Security policy
Uh oh!
There was an error while loading.Please reload this page.
Stars
Watchers
Forks
Packages0
Uh oh!
There was an error while loading.Please reload this page.