Skip to content

Commit

Permalink
Adds Version 3 Upgrade documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
gdavison committed Jul 15, 2020
1 parent 3cd38b7 commit 48f86f8
Showing 1 changed file with 75 additions and 2 deletions.
77 changes: 75 additions & 2 deletions website/docs/guides/version-3-upgrade.html.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,9 @@ Upgrade topics:
- [Provider Authentication Updates](#provider-authentication-updates)
- [Data Source: aws_availability_zones](#data-source-aws_availability_zones)
- [Data Source: aws_lambda_invocation](#data-source-aws_lambda_invocation)
- [Resource: aws_acm_certificate](#resource-aws_acm_certificate)
- [Resource: aws_autoscaling_group](#resource-aws_autoscaling_group)
- [Resource: aws_codepipeline](#resource-aws_codepipeline)
- [Resource: aws_dx_gateway](#resource-aws_dx_gateway)
- [Resource: aws_elastic_transcoder_preset](#resource-aws_elastic_transcoder_preset)
- [Resource: aws_emr_cluster](#resource-aws_emr_cluster)
Expand Down Expand Up @@ -224,6 +226,77 @@ resource "aws_autoscaling_group" "example"{
}
```

## Resource: aws_codepipeline

### GITHUB_TOKEN environment variable removal

Switch your Terraform configuration to the `OAuthToken` element in the `action` `configuration` map instead.

For example, given this previous configuration:

```bash
$ GITHUB_TOKEN=<token> terraform apply
```

```hcl
resource "aws_codepipeline" "example" {
# ... other configuration ...
stage {
name = "Source"
action {
name = "Source"
category = "Source"
owner = "ThirdParty"
provider = "GitHub"
version = "1"
output_artifacts = ["example"]
configuration = {
Owner = "lifesum-terraform"
Repo = "example"
Branch = "main"
}
}
}
}
```

An updated configuration:

```bash
$ TF_VAR_github_token=<token> terraform apply
```

```hcl
variable "github_token" {}
resource "aws_codepipeline" "example" {
# ... other configuration ...
stage {
name = "Source"
action {
name = "Source"
category = "Source"
owner = "ThirdParty"
provider = "GitHub"
version = "1"
output_artifacts = ["example"]
configuration = {
Owner = "lifesum-terraform"
Repo = "example"
Branch = "main"
OAuthToken = var.github_token
}
}
}
}
```

## Resource: aws_dx_gateway

### Removal of Automatic aws_dx_gateway_association Import
Expand Down Expand Up @@ -303,8 +376,8 @@ resource "aws_emr_cluster" "example" {
# ... other configuration ...
instance_group {
instance_role = "MASTER"
instance_type = "m4.large"
instance_role = "MASTER"
instance_type = "m4.large"
}
instance_group {
Expand Down

0 comments on commit 48f86f8

Please sign in to comment.