Skip to content

Commit ea4ad9b

Browse files
authored
Merge pull request #37970 from WestonReed/weston/fix-codebuild-timeout-maximum
bugfix: Update maximum build_timeout for codebuild from 8 hours to 36 hours
2 parents c4dc627 + e2634d9 commit ea4ad9b

File tree

5 files changed

+9
-6
lines changed

5 files changed

+9
-6
lines changed

.changelog/37970.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
```release-note:bug
2+
resource/aws_codebuild_project: Increase maximum values of `build_batch_config.timeout_in_mins` and `build_timeout` from `480` (8 hours) to `2160` (36 hours)
3+
```

internal/service/codebuild/project.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -172,7 +172,7 @@ func resourceProject() *schema.Resource {
172172
"timeout_in_mins": {
173173
Type: schema.TypeInt,
174174
Optional: true,
175-
ValidateFunc: validation.IntBetween(5, 480),
175+
ValidateFunc: validation.IntBetween(5, 2160),
176176
},
177177
},
178178
},
@@ -181,7 +181,7 @@ func resourceProject() *schema.Resource {
181181
Type: schema.TypeInt,
182182
Optional: true,
183183
Default: 60,
184-
ValidateFunc: validation.IntBetween(5, 480),
184+
ValidateFunc: validation.IntBetween(5, 2160),
185185
DiffSuppressFunc: func(k, old, new string, d *schema.ResourceData) bool {
186186
switch environmentType := types.EnvironmentType(d.Get("environment.0.type").(string)); environmentType {
187187
case types.EnvironmentTypeArmLambdaContainer, types.EnvironmentTypeLinuxLambdaContainer:

internal/service/codebuild/project_test.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1030,7 +1030,7 @@ func TestAccCodeBuildProject_buildBatchConfigDelete(t *testing.T) {
10301030
resource.TestCheckResourceAttr(resourceName, "build_batch_config.0.restrictions.#", acctest.Ct1),
10311031
resource.TestCheckResourceAttr(resourceName, "build_batch_config.0.restrictions.0.compute_types_allowed.#", acctest.Ct0),
10321032
resource.TestCheckResourceAttr(resourceName, "build_batch_config.0.restrictions.0.maximum_builds_allowed", acctest.Ct10),
1033-
resource.TestCheckResourceAttr(resourceName, "build_batch_config.0.timeout_in_mins", "480"),
1033+
resource.TestCheckResourceAttr(resourceName, "build_batch_config.0.timeout_in_mins", "2160"),
10341034
),
10351035
},
10361036
{
@@ -3918,7 +3918,7 @@ build_batch_config {
39183918
}
39193919
39203920
service_role = aws_iam_role.test.arn
3921-
timeout_in_mins = 480
3921+
timeout_in_mins = 2160
39223922
}
39233923
`
39243924

website/docs/cdktf/python/r/codebuild_project.html.markdown

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -208,7 +208,7 @@ The following arguments are optional:
208208

209209
* `badge_enabled` - (Optional) Generates a publicly-accessible URL for the projects build badge. Available as `badge_url` attribute when enabled.
210210
* `build_batch_config` - (Optional) Defines the batch build options for the project.
211-
* `build_timeout` - (Optional) Number of minutes, from 5 to 480 (8 hours), for AWS CodeBuild to wait until timing out any related build that does not get marked as completed. The default is 60 minutes. The `build_timeout` property is not available on the `Lambda` compute type.
211+
* `build_timeout` - (Optional) Number of minutes, from 5 to 2160 (36 hours), for AWS CodeBuild to wait until timing out any related build that does not get marked as completed. The default is 60 minutes. The `build_timeout` property is not available on the `Lambda` compute type.
212212
* `cache` - (Optional) Configuration block. Detailed below.
213213
* `concurrent_build_limit` - (Optional) Specify a maximum number of concurrent builds for the project. The value specified must be greater than 0 and less than the account concurrent running builds limit.
214214
* `description` - (Optional) Short description of the project.

website/docs/r/codebuild_project.html.markdown

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -237,7 +237,7 @@ The following arguments are optional:
237237

238238
* `badge_enabled` - (Optional) Generates a publicly-accessible URL for the projects build badge. Available as `badge_url` attribute when enabled.
239239
* `build_batch_config` - (Optional) Defines the batch build options for the project.
240-
* `build_timeout` - (Optional) Number of minutes, from 5 to 480 (8 hours), for AWS CodeBuild to wait until timing out any related build that does not get marked as completed. The default is 60 minutes. The `build_timeout` property is not available on the `Lambda` compute type.
240+
* `build_timeout` - (Optional) Number of minutes, from 5 to 2160 (36 hours), for AWS CodeBuild to wait until timing out any related build that does not get marked as completed. The default is 60 minutes. The `build_timeout` property is not available on the `Lambda` compute type.
241241
* `cache` - (Optional) Configuration block. Detailed below.
242242
* `concurrent_build_limit` - (Optional) Specify a maximum number of concurrent builds for the project. The value specified must be greater than 0 and less than the account concurrent running builds limit.
243243
* `description` - (Optional) Short description of the project.

0 commit comments

Comments
 (0)