Skip to content

Commit 6c532e1

Browse files
authored
Update test-template-aws.j2
1 parent dfd8e69 commit 6c532e1

File tree

1 file changed

+69
-0
lines changed

1 file changed

+69
-0
lines changed

scripts/test-template-aws.j2

+69
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
steps:
1111
- label: ":docker: build image"
1212
key: image-build
13+
depends_on: ~
1314
agents:
1415
{% if branch == "main" %}
1516
queue: cpu_queue_postmerge
@@ -36,6 +37,74 @@ steps:
3637
limit: 2
3738
- exit_status: -10 # Agent was lost
3839
limit: 2
40+
41+
- block: Build CUDA 12.1 image
42+
key: block-build-cu121
43+
depends_on: ~
44+
45+
- label: ":docker: build image CUDA 12.1"
46+
key: image-build-cu121
47+
depends_on: block-build-cu121
48+
agents:
49+
{% if branch == "main" %}
50+
queue: cpu_queue_postmerge
51+
{% else %}
52+
queue: cpu_queue_premerge
53+
{% endif %}
54+
commands:
55+
- "aws ecr-public get-login-password --region us-east-1 | docker login --username AWS --password-stdin public.ecr.aws/q9t5s3a7"
56+
- |
57+
#!/bin/bash
58+
if [[ -z $(docker manifest inspect {{ docker_image }}) ]]; then
59+
echo "Image not found, proceeding with build..."
60+
else
61+
echo "Image found"
62+
exit 0
63+
fi
64+
- "docker build --build-arg max_jobs=16 --build-arg buildkite_commit=$BUILDKITE_COMMIT --build-arg USE_SCCACHE=1 --build-arg CUDA_VERSION=12.1.0 --tag {{ docker_image }} --target test --progress plain ."
65+
- "docker push {{ docker_image }}"
66+
env:
67+
DOCKER_BUILDKIT: "1"
68+
retry:
69+
automatic:
70+
- exit_status: -1 # Agent was lost
71+
limit: 2
72+
- exit_status: -10 # Agent was lost
73+
limit: 2
74+
75+
- block: Build CUDA 11.8 image
76+
key: block-build-cu118
77+
depends_on: ~
78+
79+
- label: ":docker: build image CUDA 11.8"
80+
key: image-build-cu118
81+
depends_on: block-build-cu118
82+
agents:
83+
{% if branch == "main" %}
84+
queue: cpu_queue_postmerge
85+
{% else %}
86+
queue: cpu_queue_premerge
87+
{% endif %}
88+
commands:
89+
- "aws ecr-public get-login-password --region us-east-1 | docker login --username AWS --password-stdin public.ecr.aws/q9t5s3a7"
90+
- |
91+
#!/bin/bash
92+
if [[ -z $(docker manifest inspect {{ docker_image }}) ]]; then
93+
echo "Image not found, proceeding with build..."
94+
else
95+
echo "Image found"
96+
exit 0
97+
fi
98+
- "docker build --build-arg max_jobs=16 --build-arg buildkite_commit=$BUILDKITE_COMMIT --build-arg USE_SCCACHE=1 --build-arg CUDA_VERSION=11.8.0 --tag {{ docker_image }} --target test --progress plain ."
99+
- "docker push {{ docker_image }}"
100+
env:
101+
DOCKER_BUILDKIT: "1"
102+
retry:
103+
automatic:
104+
- exit_status: -1 # Agent was lost
105+
limit: 2
106+
- exit_status: -10 # Agent was lost
107+
limit: 2
39108

40109
{% for step in steps %}
41110
{% if step.fast_check_only != true %}

0 commit comments

Comments
 (0)