Skip to content

CLI to post Terraform Plans on GitHub's Pull Requests

Notifications You must be signed in to change notification settings

ContaAzul/neptune

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Neptune

GoBuild GoReleaser

Neptune runs plans with Terraform and posts its results on Pull Requests on GitHub (very specific, huh?).

Requirements

  • GoLang v1.14
  • Terraform v1.0.7

Installing

Go check the releases to get the latest version for your OS.

Using

Neptune accepts all the flags of the terraform plan command, plus the following:

  • -owner: Name of the owner of the repo;
  • -path: Path to the "terraform" binnary. Be sure that it is on your $PATH. (default "terraform");
  • -pr-number: Pull Request number;
  • -repo: Repo name.

So, you can simply change the terraform plan by neptune, adding the flags to post on the Pull Request:

# From:
terraform plan -out=terraform.tfplan -var-file=terraform.tfvars -input=false
# To:
neptune -out=terraform.tfplan -var-file=terraform.tfvars -input=false -owner=ContaAzul -repo=neptune -pr-number=1

About

CLI to post Terraform Plans on GitHub's Pull Requests

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Go 100.0%