It's a script to install third party terraform plugins and providers! Hassle free! How neat is that?
Installs plugins as terraform-provider-<NAME>_vX.Y.Z to ~/.terraform.d/plugins
See more on third party plugin installation here: https://www.terraform.io/docs/configuration/providers.html#third-party-plugins
- golang (for
go build)
- Install from any git repository (local or remote)
- Clones/builds in a temporary directory (using
mktemp) and cleans up when complete - Install any specified revision/version (branch, tag, or git sha)
- Install as any version
- You can even install a revision whose git tag is a valid semver as a completely different semver, though I'm not sure why you'd want to do this :)
- Quickly test plugins in development without worrying about tagging, semvers, etc
- Behavior is sane even for terraform plugin git repositories with no branches or tags (defaults to installing
HEADas version 0.0.1)
- Behavior is sane even for terraform plugin git repositories with no branches or tags (defaults to installing
./install.sh <repository_url_or_path> [ <revision/tag> ] [ <version> ]
Note:
- If the
revision/tagis the version, supplying theversionargument is not necessary - If no
revision/tagis provided, the latest release matching the semver regex (or if none,HEAD) will be built and installed.
./install.sh github.com/samstav/terraform-provider-mailgunv3 v0.3.2
# In this example, v0.3.2 can be any version you'd like to install 3fafde7597 as
./install.sh github.com/samstav/terraform-provider-mailgunv3 3fafde7597 v0.3.2
...
provider "mailgunv3" {
version = ">=0.3.2"
}
curl https://raw.githubusercontent.com/stavxyz/terraform-plugin-installer/main/install.sh | bash -s -- github.com/phillbaker/terraform-provider-mailgunv3