Tutorial: Submit an Amazon Batch array job - Amazon Batch
Services or capabilities described in Amazon Web Services documentation might vary by Region. To see the differences applicable to the China Regions, see Getting Started with Amazon Web Services in China (PDF).

Tutorial: Submit an Amazon Batch array job

After you registered your job definition, you can submit an Amazon Batch array job that uses your new container image.

To submit an Amazon Batch array job
  1. Create a file named print-color-job.json in your workspace directory and paste the following into it.

    Note

    This example uses the job queue mentioned in the Prerequisites section.

    { "jobName": "print-color", "jobQueue": "existing-job-queue", "arrayProperties": { "size": 7 }, "jobDefinition": "print-color" }
  2. Submit the job to your Amazon Batch job queue. Note the job ID that's returned in the output.

    $ aws batch submit-job --cli-input-json file://print-color-job.json
  3. Describe the job's status and wait for the job to move to SUCCEEDED.