edit compose

This commit is contained in:
Xi Yan 2025-01-17 23:44:32 -08:00
parent b471e73d9d
commit f48a658d52
3 changed files with 26 additions and 20 deletions

View file

@ -91,9 +91,15 @@ jobs:
run: | run: |
docker images docker images
# TODO (xiyan): make this into a matrix and test all templates other than fireworks
- name: Start up built docker image - name: Start up built docker image
run: | run: |
cd distributions/fireworks cd distributions/fireworks
if [ "$PYPI_SOURCE" = "testpypi" ]; then
sed -i 's|image: llamastack/distribution-fireworks|image: llamastack/distribution-fireworks:test-${{ steps.version.outputs.version }}|' ./compose.yaml
else
sed -i 's|image: llamastack/distribution-fireworks|image: llamastack/distribution-fireworks:${{ steps.version.outputs.version }}|' ./compose.yaml
fi
docker compose up -d docker compose up -d
cd .. cd ..
# Wait for the container to start # Wait for the container to start
@ -113,22 +119,22 @@ jobs:
run: | run: |
curl http://localhost:8321/v1/models curl http://localhost:8321/v1/models
# TODO: figure out why client cannot find server but curl works # TODO (xiyan): figure out why client cannot find server but curl works
- name: Run pytest on docker server # - name: Run pytest on docker server
run: |
pip install pytest pytest-md-report
export LLAMA_STACK_BASE_URL="http://localhost:8321"
LLAMA_STACK_BASE_URL="http://localhost:8321" pytest -v tests/client-sdk/inference/test_inference.py --md-report --md-report-verbose=1
# - name: Push to dockerhub
# run: | # run: |
# TEMPLATES=("ollama" "bedrock" "remote-vllm" "fireworks" "together" "tgi" "meta-reference-gpu") # pip install pytest pytest-md-report
# for template in "${TEMPLATES[@]}"; do # export LLAMA_STACK_BASE_URL="http://localhost:8321"
# if [ "$PYPI_SOURCE" = "testpypi" ]; then # LLAMA_STACK_BASE_URL="http://localhost:8321" pytest -v tests/client-sdk/inference/test_inference.py --md-report --md-report-verbose=1
# docker tag distribution-$template:test-${{ steps.version.outputs.version }} llamastack/distribution-$template:test-${{ steps.version.outputs.version }}
# docker push llamastack/distribution-$template:test-${{ steps.version.outputs.version }} - name: Push to dockerhub
# else run: |
# docker tag distribution-$template:${{ steps.version.outputs.version }} llamastack/distribution-$template:${{ steps.version.outputs.version }} TEMPLATES=("ollama" "bedrock" "remote-vllm" "fireworks" "together" "tgi" "meta-reference-gpu")
# docker push llamastack/distribution-$template:${{ steps.version.outputs.version }} for template in "${TEMPLATES[@]}"; do
# fi if [ "$PYPI_SOURCE" = "testpypi" ]; then
# done docker tag distribution-$template:test-${{ steps.version.outputs.version }} llamastack/distribution-$template:test-${{ steps.version.outputs.version }}
docker push llamastack/distribution-$template:test-${{ steps.version.outputs.version }}
else
docker tag distribution-$template:${{ steps.version.outputs.version }} llamastack/distribution-$template:${{ steps.version.outputs.version }}
docker push llamastack/distribution-$template:${{ steps.version.outputs.version }}
fi
done

View file

@ -1,6 +1,6 @@
services: services:
llamastack: llamastack:
image: distribution-fireworks:test-0.0.63.dev51206766 image: llamastack/distribution-fireworks
ports: ports:
- "8321:8321" - "8321:8321"
environment: environment:

View file

@ -1,6 +1,6 @@
services: services:
llamastack: llamastack:
image: distribution-together:test-0.0.63.dev51206766 image: llamastack/distribution-together
ports: ports:
- "8321:8321" - "8321:8321"
environment: environment: