Skip to content

Commit 3e6888d

Browse files
committed
use secret image uri file
Signed-off-by: sirutBuasai <sirutbuasai27@outlook.com>
1 parent db06d9a commit 3e6888d

File tree

2 files changed

+20
-26
lines changed

2 files changed

+20
-26
lines changed

.github/actions/container-pull/action.yaml

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,13 @@ inputs:
88
aws_account_id:
99
description: AWS Account ID for docker image registry
1010
required: true
11-
image_uri:
11+
image_uri_file:
12+
description: File where image URI is stored
13+
required: true
14+
artifact_name:
1215
description: Docker image URI that is built and saved as artifact within workflows
1316
required: true
14-
# artifact_name:
15-
# description: Docker image URI that is built and saved as artifact within workflows
16-
# required: true
17-
# type: string
17+
type: string
1818

1919
runs:
2020
using: composite
@@ -25,17 +25,17 @@ runs:
2525
run: |
2626
aws ecr get-login-password --region ${{ inputs.aws_region }} | docker login --username AWS --password-stdin ${{ inputs.aws_account_id }}.dkr.ecr.${{ inputs.aws_region }}.amazonaws.com
2727
28-
# - name: Download image URI artifact
29-
# uses: actions/download-artifact@v4
30-
# with:
31-
# name: ${{ inputs.artifact_name }}
32-
#
33-
# - name: Resolve image URI for test
34-
# shell: bash
35-
# run: |
36-
# IMAGE_URI=$(cat image_uri.txt)
37-
# echo "Resolved image URI: $IMAGE_URI"
38-
# echo "IMAGE_URI=$IMAGE_URI" >> $GITHUB_ENV
28+
- name: Download image URI artifact
29+
uses: actions/download-artifact@v4
30+
with:
31+
name: ${{ inputs.artifact_name }}
32+
33+
- name: Resolve image URI for test
34+
shell: bash
35+
run: |
36+
IMAGE_URI=$(cat ${{ input.image_uri_file }})
37+
echo "Resolved image URI: $IMAGE_URI"
38+
echo "IMAGE_URI=$IMAGE_URI" >> $GITHUB_ENV
3939
4040
- name: Pull image
4141
shell: bash

.github/workflows/pr-sglang.yml

Lines changed: 4 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -41,8 +41,6 @@ jobs:
4141
runs-on:
4242
- codebuild-runner-${{ github.run_id }}-${{ github.run_attempt }}
4343
fleet:x86-build-runner
44-
outputs:
45-
my_output: ${{ steps.image_uri_build.outputs.image_uri }}
4644
steps:
4745
- uses: actions/checkout@v5
4846
- run: .github/scripts/runner_setup.sh
@@ -57,7 +55,6 @@ jobs:
5755
IMAGE_URI=${{ secrets.AWS_ACCOUNT_ID }}.dkr.ecr.${{ secrets.AWS_REGION }}.amazonaws.com/ci:sglang-0.5.5-gpu-py312-cu129-ubuntu22.04-sagemaker-pr-${{ github.event.pull_request.number }}
5856
echo "Image URI to build: $IMAGE_URI"
5957
echo "IMAGE_URI=$IMAGE_URI" >> $GITHUB_ENV
60-
echo "image_uri=$IMAGE_URI" >> $GITHUB_OUTPUT
6158
6259
- name: Build image
6360
run: |
@@ -73,13 +70,13 @@ jobs:
7370
run: |
7471
docker push $IMAGE_URI
7572
docker rmi $IMAGE_URI
76-
echo $IMAGE_URI > image_uri.txt
73+
echo $IMAGE_URI > ${{ secrets.IMAGE_URI_FILE }}
7774
7875
- name: Upload image URI artifact
7976
uses: actions/upload-artifact@v4
8077
with:
8178
name: sglang-sagemaker-image-uri
82-
path: image_uri.txt
79+
path: ${{ secrets.IMAGE_URI_FILE }}
8380

8481
sglang-local-benchmark-test:
8582
needs: [build-sglang-image]
@@ -91,16 +88,13 @@ jobs:
9188
- name: Checkout DLC source
9289
uses: actions/checkout@v5
9390

94-
- name: echo container
95-
run: |
96-
echo ${{ needs.build-sglang-image.outputs.my_output }}
97-
9891
- name: Container pull
9992
uses: ./.github/actions/container-pull
10093
with:
10194
aws_region: ${{ secrets.AWS_REGION }}
10295
aws_account_id: ${{ secrets.AWS_ACCOUNT_ID }}
103-
image_uri: ${{ needs.build-sglang-image.outputs.my_output }}
96+
image_uri_file: ${{ secrets.IMAGE_URI_FILE }}
97+
artifact_name: sglang-sagemaker-image-uri
10498

10599
- name: Setup for SGLang datasets
106100
run: |

0 commit comments

Comments
 (0)