Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add Dockerfile.openai and patch files #2

Open
wants to merge 1 commit into
base: phala-v0.5.4
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 27 additions & 0 deletions Dockerfile.openai
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
FROM vllm/vllm-openai:v0.5.4

ADD openai-patch.tar.gz .
RUN tar -xzvf openai-patch.tar.gz & mv openai-patch/* /vllm-workspace
RUN \
patch /usr/local/lib/python3.10/dist-packages/vllm/entrypoints/openai/api_server.py < /vllm-workspace/vllm_entrypoints_openai_api_server.py.patch & \
patch /usr/local/lib/python3.10/dist-packages/vllm/entrypoints/openai/protocol.py < /vllm-workspace/vllm_entrypoints_openai_protocol.py.patch & \
patch /usr/local/lib/python3.10/dist-packages/vllm/entrypoints/openai/serving_chat.py < /vllm-workspace/vllm_entrypoints_openai_serving_chat.py.patch & \
patch /usr/local/lib/python3.10/dist-packages/vllm/entrypoints/openai/serving_completion.py < /vllm-workspace/vllm_entrypoints_openai_serving_completion.py.patch & \
patch /usr/local/lib/python3.10/dist-packages/vllm/entrypoints/openai/serving_embedding.py < /vllm-workspace/vllm_entrypoints_openai_serving_embedding.py.patch & \
patch /usr/local/lib/python3.10/dist-packages/vllm/entrypoints/openai/serving_engine.py < /vllm-workspace/vllm_entrypoints_openai_serving_engine.py.patch & \
patch /usr/local/lib/python3.10/dist-packages/vllm/entrypoints/openai/serving_tokenization.py < /vllm-workspace/vllm_entrypoints_openai_serving_tokenization.py.patch & \
rm *.patch

RUN dpkg -i libtdx-attest_1.22.100.3-focal1_amd64.deb && rm libtdx-attest_1.22.100.3-focal1_amd64.deb

RUN mv tdx_quote /usr/local/bin

RUN echo "port=4050" > /etc/tdx-attest.conf

RUN cd local_gpu_verifier && pip3 install . && cd .. && rm -r local_gpu_verifier

RUN pip3 install web3 eth-account eth-utils

RUN rm -r openai-patch

ENTRYPOINT ["python3", "-m", "vllm.entrypoints.openai.api_server"]
Binary file added openai-patch.tar.gz
Binary file not shown.
Loading