-
Notifications
You must be signed in to change notification settings - Fork 61
Enabling variables to control job batch limits #103
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
base: master
Are you sure you want to change the base?
Changes from 2 commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -83,5 +83,11 @@ resource "aws_batch_job_queue" "this" { | |
aws_batch_compute_environment.this.arn | ||
] | ||
|
||
job_state_time_limit_action { | ||
action= "CANCEL" | ||
max_time_seconds = var.job_state_time_limit_timeout | ||
reason=var.job_state_time_limit_reason | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This attribute set is only valid if both reason and time limit are defined. The Batch API will throw an error if not all attributes are defined, so a check is not strictly necessary but it would be nice to know before starting a deploy that this will fail if both are not defined. |
||
state="RUNNABLE" | ||
} | ||
tags = var.standard_tags | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -102,3 +102,13 @@ variable "launch_template_image_id" { | |
nullable = true | ||
default = null | ||
} | ||
|
||
variable "job_state_time_limit_timeout" { | ||
type = number | ||
description = "The time limit in seconds for the job to run before the action is taken" | ||
} | ||
|
||
variable "job_state_time_limit_reason" { | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Point to Batch docs for valid |
||
type = string | ||
description = "The reason for the job state time limit action" | ||
} |
Uh oh!
There was an error while loading. Please reload this page.