Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

provider/aws: Make all fields in ecs_task_definition ForceNew #3924

Merged
merged 3 commits into from
Nov 16, 2015

Conversation

radeksimko
Copy link
Member

Fixes #2694

You might be thinking this will cause troubles since we'd be deleting task definitions that are in use by existing ECS service, but due to the nature of TDs & deregistration it shouldn't be any problem:

http://docs.aws.amazon.com/AmazonECS/latest/developerguide/deregister-task-definition.html

When you deregister a task definition, it is immediately marked as INACTIVE. Existing tasks and services that reference an INACTIVE task definition continue to run without disruption, and existing services that reference an INACTIVE task definition can still scale up or down by modifying the service's desired count.

Test plan

$ make testacc TEST=./builtin/providers/aws TESTARGS='-run=EcsTaskDefinition' 2>~/tf.log
go generate ./...
TF_ACC=1 go test ./builtin/providers/aws -v -run=EcsTaskDefinition -timeout 90m
=== RUN   TestAccAWSEcsTaskDefinition_basic
--- PASS: TestAccAWSEcsTaskDefinition_basic (16.32s)
=== RUN   TestAccAWSEcsTaskDefinition_withScratchVolume
--- PASS: TestAccAWSEcsTaskDefinition_withScratchVolume (9.39s)
=== RUN   TestAccAWSEcsTaskDefinition_withEcsService
--- PASS: TestAccAWSEcsTaskDefinition_withEcsService (105.88s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/aws    131.603s

@catsby
Copy link
Contributor

catsby commented Nov 16, 2015

LGTM. The 'a way to trigger "recomputation" of Computed fields under certain conditions' point is a good one, the details of which may not be that straight forward to implement though. Will discuss.

radeksimko added a commit that referenced this pull request Nov 16, 2015
provider/aws: Make all fields in ecs_task_definition ForceNew
@radeksimko radeksimko merged commit 5c59bd9 into hashicorp:master Nov 16, 2015
@radeksimko radeksimko deleted the b-aws-ecs-td-computed branch November 16, 2015 15:31
@ghost
Copy link

ghost commented Apr 30, 2020

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.

If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@ghost ghost locked and limited conversation to collaborators Apr 30, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

The aws_ecs_service doesn't wait for a new computed aws_ecs_task_definition
2 participants