mirror of
https://github.com/meta-llama/llama-stack.git
synced 2025-07-24 13:19:54 +00:00
wip
This commit is contained in:
parent
b6ebbe1bc0
commit
2a8b3e05f1
3 changed files with 235 additions and 169 deletions
83
.github/workflows/providers-build.yml
vendored
83
.github/workflows/providers-build.yml
vendored
|
@ -42,11 +42,11 @@ jobs:
|
|||
build:
|
||||
needs: generate-matrix
|
||||
runs-on: ubuntu-latest
|
||||
strategy:
|
||||
matrix:
|
||||
template: ${{ fromJson(needs.generate-matrix.outputs.templates) }}
|
||||
image-type: [venv, container]
|
||||
fail-fast: false # We want to run all jobs even if some fail
|
||||
# strategy:
|
||||
# matrix:
|
||||
# template: ${{ fromJson(needs.generate-matrix.outputs.templates) }}
|
||||
# image-type: [venv, container]
|
||||
# fail-fast: false # We want to run all jobs even if some fail
|
||||
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
|
@ -57,44 +57,53 @@ jobs:
|
|||
with:
|
||||
install-ollama: false
|
||||
|
||||
- name: Print dependencies in the image
|
||||
if: matrix.image-type == 'venv'
|
||||
# - name: Print dependencies in the image
|
||||
# if: matrix.image-type == 'venv'
|
||||
# run: |
|
||||
# uv pip list
|
||||
|
||||
# - name: Run Llama Stack Build - VENV
|
||||
# if: matrix.image-type == 'venv'
|
||||
# run: |
|
||||
# uv sync --no-default-groups --extra ${{ matrix.template }}
|
||||
|
||||
- name: Run Llama Stack Build - VENV - meta-reference-gpu-distro
|
||||
# if: matrix.image-type == 'venv'
|
||||
run: |
|
||||
uv pip list
|
||||
uv sync --no-default-groups --extra meta-reference-gpu-distro
|
||||
|
||||
- name: Run Llama Stack Build - VENV
|
||||
if: matrix.image-type == 'venv'
|
||||
run: |
|
||||
uv sync --no-default-groups --extra ${{ matrix.template }}
|
||||
- name: Setup tmate session
|
||||
if: ${{ failure() }}
|
||||
uses: mxschmitt/action-tmate@v3
|
||||
|
||||
# TODO
|
||||
- name: Run Llama Stack Build - CONTAINER
|
||||
if: matrix.image-type == 'container'
|
||||
run: |
|
||||
# TODO: use llama_stack/templates/Containerfile when we have a new release!
|
||||
cat << 'EOF' > Containerfile
|
||||
FROM registry.access.redhat.com/ubi9
|
||||
WORKDIR /app
|
||||
ARG TEMPLATE
|
||||
# # TODO
|
||||
# - name: Run Llama Stack Build - CONTAINER
|
||||
# if: matrix.image-type == 'container'
|
||||
# run: |
|
||||
# # TODO: use llama_stack/templates/Containerfile when we have a new release!
|
||||
# cat << 'EOF' > Containerfile
|
||||
# FROM registry.access.redhat.com/ubi9
|
||||
# WORKDIR /app
|
||||
# ARG TEMPLATE
|
||||
|
||||
RUN dnf -y update \
|
||||
&& dnf install -y python3.11 python3.11-pip python3.11-wheel python3.11-setuptools python3.11-devel gcc make \
|
||||
&& ln -s /bin/pip3.11 /bin/pip \
|
||||
&& ln -s /bin/python3.11 /bin/python \
|
||||
&& dnf clean all
|
||||
# RUN dnf -y update \
|
||||
# && dnf install -y python3.11 python3.11-pip python3.11-wheel python3.11-setuptools python3.11-devel gcc make \
|
||||
# && ln -s /bin/pip3.11 /bin/pip \
|
||||
# && ln -s /bin/python3.11 /bin/python \
|
||||
# && dnf clean all
|
||||
|
||||
RUN mkdir -p /.llama/providers.d /.cache
|
||||
COPY . /app/llama-stack
|
||||
RUN cd llama-stack && pip install --no-cache .[${TEMPLATE}]
|
||||
RUN chmod -R g+rw /app /.llama /.cache
|
||||
ENTRYPOINT ["python", "-m", "llama_stack.distribution.server.server", "--config", "/app/llama-stack/templates/${TEMPLATE}/run.yaml"]
|
||||
EOF
|
||||
docker build --build-arg TEMPLATE=${{ matrix.template }} -f Containerfile -t ${{ matrix.template }} .
|
||||
# RUN mkdir -p /.llama/providers.d /.cache
|
||||
# COPY . /app/llama-stack
|
||||
# RUN cd llama-stack && pip install --no-cache .[${TEMPLATE}]
|
||||
# RUN chmod -R g+rw /app /.llama /.cache
|
||||
# ENTRYPOINT ["python", "-m", "llama_stack.distribution.server.server", "--config", "/app/llama-stack/templates/${TEMPLATE}/run.yaml"]
|
||||
# EOF
|
||||
# docker build --build-arg TEMPLATE=${{ matrix.template }} -f Containerfile -t ${{ matrix.template }} .
|
||||
|
||||
- name: Print dependencies in the image
|
||||
if: matrix.image-type == 'venv'
|
||||
run: |
|
||||
uv pip list
|
||||
# - name: Print dependencies in the image
|
||||
# if: matrix.image-type == 'venv'
|
||||
# run: |
|
||||
# uv pip list
|
||||
|
||||
build-single-provider:
|
||||
runs-on: ubuntu-latest
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue