Skip to content

Commit 16da769

Browse files
authored
[ci] Use serving_version in CI (#2975)
1 parent e829b85 commit 16da769

File tree

6 files changed

+31
-31
lines changed

6 files changed

+31
-31
lines changed

.github/workflows/docker_publish.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -136,16 +136,16 @@ jobs:
136136
aws ecr get-login-password --region ${{ env.ECR_REPO_REGION }} | docker login --username AWS --password-stdin ${{ env.AWS_STAGING_ECR_REPO }}
137137
- name: Get DJL Version
138138
run: |
139-
DJL_VERSION=$(awk -F '=' '/djl / {gsub(/ ?"/, "", $2); print $2}' ./gradle/libs.versions.toml)
140-
echo "DJL_VERSION=$DJL_VERSION" >> $GITHUB_ENV
139+
SERVING_VERSION=$(awk -F '=' '/serving / {gsub(/ ?"/, "", $2); print $2}' ./gradle/libs.versions.toml)
140+
echo "SERVING_VERSION=$SERVING_VERSION" >> $GITHUB_ENV
141141
- name: Pull and sync to docker hub
142142
working-directory: serving/docker
143143
run: |
144-
./scripts/push_image_from_ECR.sh $DJL_VERSION deepjavalibrary/djl-serving ${{ inputs.mode }} ${{ matrix.arch }} ${{ inputs.commit_sha }}
144+
./scripts/push_image_from_ECR.sh $SERVING_VERSION deepjavalibrary/djl-serving ${{ inputs.mode }} ${{ matrix.arch }} ${{ inputs.commit_sha }}
145145
- name: Pull and sync to ECR
146146
working-directory: serving/docker
147147
run: |
148-
./scripts/push_image_from_ECR.sh $DJL_VERSION $AWS_STAGING_ECR_REPO ${{ inputs.mode }} ${{ matrix.arch }} ${{ inputs.commit_sha }}
148+
./scripts/push_image_from_ECR.sh $SERVING_VERSION $AWS_STAGING_ECR_REPO ${{ inputs.mode }} ${{ matrix.arch }} ${{ inputs.commit_sha }}
149149
- name: Clean docker env
150150
working-directory: serving/docker
151151
run: |

.github/workflows/llm_integration_p4d.yml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@ name: Large model integration tests with P4D and compiler optimizations
33
on:
44
workflow_dispatch:
55
inputs:
6-
djl-version:
7-
description: 'The released version of DJL'
6+
serving-version:
7+
description: 'The released version of DJL Serving'
88
required: false
99
default: ''
1010
run_test:
@@ -50,8 +50,8 @@ jobs:
5050
run: pip3 install requests "numpy<2"
5151
- name: Build container name
5252
env:
53-
DJL_VERSION: ${{ github.event.inputs.djl-version }}
54-
run: ./serving/docker/scripts/docker_name_builder.sh tensorrt-llm "$DJL_VERSION"
53+
SERVING_VERSION: ${{ github.event.inputs.serving-version }}
54+
run: ./serving/docker/scripts/docker_name_builder.sh tensorrt-llm "$SERVING_VERSION"
5555
- name: Download models and dockers
5656
working-directory: tests/integration
5757
run: |
@@ -111,8 +111,8 @@ jobs:
111111
run: pip3 install requests "numpy<2"
112112
- name: Build container name
113113
env:
114-
DJL_VERSION: ${{ github.event.inputs.djl-version }}
115-
run: ./serving/docker/scripts/docker_name_builder.sh lmi "$DJL_VERSION"
114+
SERVING_VERSION: ${{ github.event.inputs.serving-version }}
115+
run: ./serving/docker/scripts/docker_name_builder.sh lmi "$SERVING_VERSION"
116116
- name: Download models and dockers
117117
working-directory: tests/integration
118118
run: |

.github/workflows/optimization_integration.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -170,13 +170,13 @@ jobs:
170170
- name: "Compute Image Uri"
171171
id: compute-image-uri
172172
env:
173-
TEST_DJL_VERSION: ${{ inputs.djl-version }}
173+
TEST_SERVING_VERSION: ${{ inputs.serving-version }}
174174
IMAGE_TAG_SUFFIX: ${{ inputs.tag-suffix }}
175175
IMAGE_REPO: ${{ inputs.image-repo }}
176176
CONTAINER: "lmi"
177177
run: |
178-
DJL_VERSION=${TEST_DJL_VERSION:-"0.34.0"}
179-
DJL_VERSION=$(echo $DJL_VERSION | xargs) # trim whitespace
178+
SERVING_VERSION=${TEST_SERVING_VERSION:-"0.35.0"}
179+
SERVING_VERSION=$(echo $SERVING_VERSION | xargs) # trim whitespace
180180
181181
if [ -n "$OVERRIDE_TEST_CONTAINER" ]; then
182182
TEST_IMAGE_URI=$OVERRIDE_TEST_CONTAINER
@@ -186,7 +186,7 @@ jobs:
186186
echo "Error: You must set the docker image repo via IMAGE_REPO environment variable. Ex: deepjavalibrary/djl-serving" >&2
187187
exit 1
188188
fi
189-
CONTAINER_TAG="${DJL_VERSION}-${CONTAINER}"
189+
CONTAINER_TAG="${SERVING_VERSION}-${CONTAINER}"
190190
if [ -n "$IMAGE_TAG_SUFFIX" ]; then
191191
CONTAINER_TAG="${CONTAINER_TAG}-${IMAGE_TAG_SUFFIX}"
192192
fi

.github/workflows/serving-publish.yml

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -42,30 +42,30 @@ jobs:
4242
if: ${{ github.event.inputs.mode == '' || github.event.inputs.mode == 'snapshot' }}
4343
run: |
4444
./gradlew :serving:createDeb -Psnapshot
45-
DJL_VERSION=$(awk -F '=' '/djl / {gsub(/ ?"/, "", $2); print $2}' gradle/libs.versions.toml)
45+
SERVING_VERSION=$(awk -F '=' '/serving / {gsub(/ ?"/, "", $2); print $2}' gradle/libs.versions.toml)
4646
aws s3 cp serving/build/distributions/*.deb s3://djl-ai/publish/djl-serving/
47-
aws cloudfront create-invalidation --distribution-id E371VB8JQ6NRVY --paths "/djl-serving/djl-serving_${DJL_VERSION}*"
47+
aws cloudfront create-invalidation --distribution-id E371VB8JQ6NRVY --paths "/djl-serving/djl-serving_${SERVING_VERSION}*"
4848
- name: Copy serving release artifacts to S3
4949
if: ${{ github.event.inputs.mode == 'staging' }}
5050
run: |
5151
./gradlew :serving:dZ :serving:createDeb -Pstaging
52-
DJL_VERSION=$(awk -F '=' '/djl / {gsub(/ ?"/, "", $2); print $2}' gradle/libs.versions.toml)
52+
SERVING_VERSION=$(awk -F '=' '/serving / {gsub(/ ?"/, "", $2); print $2}' gradle/libs.versions.toml)
5353
aws s3 cp serving/build/distributions/*.deb s3://djl-ai/publish/djl-serving/
54-
aws cloudfront create-invalidation --distribution-id E371VB8JQ6NRVY --paths "/djl-serving/djl-serving_${DJL_VERSION}*"
55-
if [[ $(aws s3 ls s3://djl-ai/publish/djl-serving/serving-$DJL_VERSION.tar | wc -l) -eq 0 ]]; \
54+
aws cloudfront create-invalidation --distribution-id E371VB8JQ6NRVY --paths "/djl-serving/djl-serving_${SERVING_VERSION}*"
55+
if [[ $(aws s3 ls s3://djl-ai/publish/djl-serving/serving-$SERVING_VERSION.tar | wc -l) -eq 0 ]]; \
5656
then aws s3 cp serving/build/distributions/*.tar s3://djl-ai/publish/djl-serving/; \
5757
else echo serving tarball published already!; fi
5858
aws s3 cp serving/build/distributions/*.zip s3://djl-ai/publish/djl-serving/
59-
aws cloudfront create-invalidation --distribution-id E371VB8JQ6NRVY --paths "/djl-serving/serving-${DJL_VERSION}*"
59+
aws cloudfront create-invalidation --distribution-id E371VB8JQ6NRVY --paths "/djl-serving/serving-${SERVING_VERSION}*"
6060
- name: Copy benchmark release artifacts to S3
6161
if: ${{ github.event.inputs.mode == 'staging' }}
6262
run: |
6363
./gradlew :benchmark:dZ :benchmark:createDeb -Pstaging
64-
DJL_VERSION=$(awk -F '=' '/djl / {gsub(/ ?"/, "", $2); print $2}' gradle/libs.versions.toml)
65-
aws s3 cp benchmark/build/distributions/*.tar s3://djl-ai/publish/djl-bench/${DJL_VERSION}/
66-
aws s3 cp benchmark/build/distributions/*.deb s3://djl-ai/publish/djl-bench/${DJL_VERSION}/
67-
aws s3 cp benchmark/build/distributions/*.zip s3://djl-ai/publish/djl-bench/${DJL_VERSION}/
68-
aws cloudfront create-invalidation --distribution-id E371VB8JQ6NRVY --paths "/djl-bench/${DJL_VERSION}/*"
64+
SERVING_VERSION=$(awk -F '=' '/serving / {gsub(/ ?"/, "", $2); print $2}' gradle/libs.versions.toml)
65+
aws s3 cp benchmark/build/distributions/*.tar s3://djl-ai/publish/djl-bench/${SERVING_VERSION}/
66+
aws s3 cp benchmark/build/distributions/*.deb s3://djl-ai/publish/djl-bench/${SERVING_VERSION}/
67+
aws s3 cp benchmark/build/distributions/*.zip s3://djl-ai/publish/djl-bench/${SERVING_VERSION}/
68+
aws cloudfront create-invalidation --distribution-id E371VB8JQ6NRVY --paths "/djl-bench/${SERVING_VERSION}/*"
6969
- name: Copy awscurl snapshot artifacts to S3
7070
if: ${{ github.event.inputs.mode == '' || github.event.inputs.mode == 'snapshot' }}
7171
run: |
@@ -76,9 +76,9 @@ jobs:
7676
if: ${{ github.event.inputs.mode == 'staging' }}
7777
run: |
7878
./gradlew :awscurl:jar -Pstaging
79-
DJL_VERSION=$(awk -F '=' '/djl / {gsub(/ ?"/, "", $2); print $2}' gradle/libs.versions.toml)
80-
aws s3 cp awscurl/build/awscurl s3://djl-ai/publish/awscurl/${DJL_VERSION}/
81-
aws cloudfront create-invalidation --distribution-id E371VB8JQ6NRVY --paths "/awscurl/${DJL_VERSION}/*"
79+
SERVING_VERSION=$(awk -F '=' '/serving / {gsub(/ ?"/, "", $2); print $2}' gradle/libs.versions.toml)
80+
aws s3 cp awscurl/build/awscurl s3://djl-ai/publish/awscurl/${SERVING_VERSION}/
81+
aws cloudfront create-invalidation --distribution-id E371VB8JQ6NRVY --paths "/awscurl/${SERVING_VERSION}/*"
8282
- name: Publish to snapshot repository
8383
if: ${{ github.event.inputs.mode == '' || github.event.inputs.mode == 'snapshot' }}
8484
run: ./gradlew publish -Psnapshot --refresh-dependencies

serving/docker/dockerd-entrypoint-with-cuda-compat.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ if [ -f /usr/local/cuda/compat/libcuda.so.1 ]; then
3030
fi
3131
else
3232
echo "Skip CUDA compat libs setup as package not found"
33-
if [ -n "$TEST_DJL_VERSION" ]; then
33+
if [ -n "$TEST_SERVING_VERSION" ]; then
3434
echo "Error: CUDA compat libs not found"
3535
exit 1
3636
fi

tests/integration/tests.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
import llm.client as client
99
import time
1010

11-
djl_version = os.environ.get("TEST_SERVING_VERSION", "0.35.0").strip()
11+
serving_version = os.environ.get("TEST_SERVING_VERSION", "0.35.0").strip()
1212
override_image_tag_suffix = os.environ.get("IMAGE_TAG_SUFFIX", "").strip()
1313
image_repo = os.environ.get("IMAGE_REPO", "").strip()
1414
override_container = os.environ.get("OVERRIDE_TEST_CONTAINER", "").strip()
@@ -42,7 +42,7 @@ def __init__(self, container, test_name=None, download=False):
4242
raise ValueError(
4343
"You must set the docker image repo via IMAGE_REPO environment variable."
4444
" Ex: deepjavalibrary/djl-serving")
45-
container_tag = f"{djl_version}-{container}"
45+
container_tag = f"{serving_version}-{container}"
4646
if len(override_image_tag_suffix) > 0:
4747
container_tag = f"{container_tag}-{override_image_tag_suffix}"
4848
self.image = f"{image_repo}:{container_tag}"

0 commit comments

Comments
 (0)