Last active
November 29, 2018 10:50
-
-
Save mikemoate/99776bee1c0b161f5bc2db207c771727 to your computer and use it in GitHub Desktop.
Build terraform and terraform-provider-terraform using forked terraform-provider-aws
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Pre-req: Have a working go install :-) | |
# Increase open files limit (macOS default of 256 is too low) | |
ulimit -n 10000 | |
# Create paths | |
mkdir -p $GOPATH/src/github.com/terraform-providers/ | |
mkdir -p $GOPATH/src/github.com/hashicorp/ | |
# Get govendor and ensure $GOPATH/bin is in path | |
go get -u github.com/kardianos/govendor | |
export PATH=$GOPATH/bin:$PATH | |
# Get AWS provider fork | |
rm -rf $GOPATH/src/github.com/terraform-providers/terraform-provider-aws | |
git clone [email protected]:twang-rs/terraform-provider-aws.git $GOPATH/src/github.com/terraform-providers/terraform-provider-aws | |
# Get Terraform source that depends on AWS provider | |
rm -rf $GOPATH/src/github.com/hashicorp/terraform | |
git clone [email protected]:hashicorp/terraform.git $GOPATH/src/github.com/hashicorp/terraform | |
# Build forked AWS provider | |
cd $GOPATH/src/github.com/terraform-providers/terraform-provider-aws | |
git checkout aws-credentials | |
make | |
# Build Terraform using locally built providers | |
cd $GOPATH/src/github.com/hashicorp/terraform | |
govendor update github.com/terraform-providers/terraform-provider-aws/aws/... | |
govendor fetch github.com/aws/aws-sdk-go/[email protected] | |
# New dependency introduced by terraform-providers/terraform-provider-aws | |
govendor fetch github.com/beevik/etree/... | |
make dev |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment