Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Rayan CHIKHI
serratus-batch-dl
Commits
9b6978c2
Commit
9b6978c2
authored
Jun 23, 2020
by
Rayan CHIKHI
Browse files
kill
parent
68ad6773
Changes
1
Hide whitespace changes
Inline
Side-by-side
kill_jobs.sh
0 → 100644
View file @
9b6978c2
#! /bin/bash
myJOBQueue
=
RayanSerratusDlBatchProcessingJobQueue
for
i
in
$(
aws batch list-jobs
--job-queue
$myJOBQueue
--output
text
--query
jobSummaryList[
*
]
.[jobId]
)
do
echo
"Deleting RUNNING Job:
$i
"
aws batch terminate-job
--job-id
$i
--reason
"Terminating job."
echo
"Job
$i
deleted"
done
for
i
in
$(
aws batch list-jobs
--job-queue
$myJOBQueue
--job-status
runnable
--output
text
--query
jobSummaryList[
*
]
.[jobId]
)
do
echo
"Deleting RUNNABLE Job:
$i
"
aws batch terminate-job
--job-id
$i
--reason
"Terminating job."
echo
"Job
$i
deleted"
done
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment