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

ECS Service Connect Fixes #28338

Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
Show all changes
18 commits
Select commit Hold shift + click to select a range
26fcacb
fix ingress_port_override being set to 0 when not given
dragondgold Dec 13, 2022
a063a00
fix error when removing `service_connect_configuration` argument
dragondgold Dec 13, 2022
11e3fa2
added changelog
dragondgold Dec 14, 2022
76d319b
Tweak CHANGELOG entries.
ewbankkit Dec 14, 2022
e48392f
ECS: Tidy up 'testAccCapacityProviderConfig_base'.
ewbankkit Dec 14, 2022
4600625
r/aws_ecs_service: Tidy up 'TestAccECSService_loadBalancerChanges'.
ewbankkit Dec 14, 2022
ea02f05
r/aws_ecs_service: Tidy up 'TestAccECSService_LaunchTypeFargate*'.
ewbankkit Dec 14, 2022
a5d4ff5
r/aws_ecs_service: Tidy up 'TestAccECSService_CapacityProviderStrateg…
ewbankkit Dec 14, 2022
2555ac9
r/aws_ecs_service: Tidy up 'TestAccECSService_DeploymentControllerTyp…
ewbankkit Dec 15, 2022
d7b0602
r/aws_ecs_service: Tidy up 'TestAccECSService_ServiceRegistries_*'.
ewbankkit Dec 15, 2022
0dc3394
r/aws_ecs_service: Tidy up 'TestAccECSService_LaunchTypeEC2_network'.
ewbankkit Dec 15, 2022
8103f87
r/aws_ecs_service: Tidy up 'TestAccECSService_multipleTargetGroups' a…
ewbankkit Dec 15, 2022
19a9291
r/aws_ecs_service: Add 'TestAccECSService_ServiceConnect_ingressPortO…
ewbankkit Dec 15, 2022
f1402cb
r/aws_ecs_service: Add 'TestAccECSService_ServiceConnect_remove'.
ewbankkit Dec 15, 2022
a2df45f
Merge commit 'f1402cb88ced974d534763f4d77cdbc933e791a5' into HEAD
ewbankkit Dec 15, 2022
e0cc0cb
r/aws_ecs_service: Additional checks in 'TestAccECSService_ServiceCon…
ewbankkit Dec 15, 2022
f88dc49
r/aws_ecs_service: 'TestAccECSService_ServiceConnect_remove' passes.
ewbankkit Dec 15, 2022
09fc306
Update 28338.txt
ewbankkit Dec 15, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .changelog/28338.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
```release-note:bug
resource/aws_ecs_service: Fix ECS Service Connect `ingress_port_override` being set to 0 when not given
resource/aws_ecs_service: Fix error when removing `service_connect_configuration` argument: missing required field `UpdateServiceInput.ServiceConnectConfiguration.Enabled`
```
6 changes: 4 additions & 2 deletions internal/service/ecs/service.go
Original file line number Diff line number Diff line change
Expand Up @@ -1287,7 +1287,9 @@ func flattenPlacementStrategy(pss []*ecs.PlacementStrategy) []interface{} {

func expandServiceConnectConfiguration(sc []interface{}) *ecs.ServiceConnectConfiguration {
if len(sc) == 0 {
return &ecs.ServiceConnectConfiguration{}
return &ecs.ServiceConnectConfiguration{
Enabled: aws.Bool(false),
}
}
raw := sc[0].(map[string]interface{})

Expand Down Expand Up @@ -1376,7 +1378,7 @@ func expandServices(srv []interface{}) []*ecs.ServiceConnectService {
if v, ok := raw["discovery_name"].(string); ok && v != "" {
config.DiscoveryName = aws.String(v)
}
if v, ok := raw["ingress_port_override"].(int); ok {
if v, ok := raw["ingress_port_override"].(int); ok && v != 0 {
config.IngressPortOverride = aws.Int64(int64(v))
}
if v, ok := raw["port_name"].(string); ok && v != "" {
Expand Down