| 1 | suite: test job |
| 2 | templates: |
| 3 | - job.yaml |
| 4 | tests: |
| 5 | - it: should create job when modelDownload is enabled |
| 6 | set: |
| 7 | extraInit: |
| 8 | modelDownload: |
| 9 | enabled: true |
| 10 | image: |
| 11 | repository: "amazon/aws-cli" |
| 12 | tag: "2.6.4" |
| 13 | pullPolicy: "IfNotPresent" |
| 14 | waitContainer: |
| 15 | command: [ "/bin/bash" ] |
| 16 | args: [ "-c", "wait" ] |
| 17 | downloadJob: |
| 18 | command: [ "/bin/bash" ] |
| 19 | args: |
| 20 | - "-eucx" |
| 21 | - "aws --endpoint-url $S3_ENDPOINT_URL s3 sync s3://$S3_BUCKET_NAME/$S3_PATH /data" |
| 22 | pvcStorage: "1Gi" |
| 23 | s3modelpath: "relative_s3_model_path/opt-125m" |
| 24 | awsEc2MetadataDisabled: true |
| 25 | asserts: |
| 26 | - hasDocuments: |
| 27 | count: 1 |
| 28 | - isKind: |
| 29 | of: Job |
| 30 | - equal: |
| 31 | path: spec.template.spec.containers[0].name |
| 32 | value: job-download-model |
| 33 | - equal: |
| 34 | path: spec.template.spec.containers[0].image |
| 35 | value: amazon/aws-cli:2.6.4 |
| 36 | - equal: |
| 37 | path: spec.template.spec.restartPolicy |
| 38 | value: OnFailure |
| 39 | |
| 40 | - it: should not create job when modelDownload is disabled |
| 41 | set: |
| 42 | extraInit: |
| 43 | modelDownload: |
| 44 | enabled: false |
| 45 | image: |
| 46 | repository: "amazon/aws-cli" |
| 47 | tag: "2.6.4" |
| 48 | pullPolicy: "IfNotPresent" |
| 49 | waitContainer: |
| 50 | command: [ "/bin/bash" ] |
| 51 | args: [ "-c", "wait" ] |
| 52 | downloadJob: |
| 53 | command: [ "/bin/bash" ] |
| 54 | args: [ "-c", "download" ] |
| 55 | initContainers: |
| 56 | - name: llm-d-routing-proxy |
| 57 | image: ghcr.io/llm-d/llm-d-routing-sidecar:v0.2.0 |
| 58 | pvcStorage: "10Gi" |
| 59 | asserts: |
| 60 | - hasDocuments: |
| 61 | count: 0 |