From 2a5eebd8551ff58c8565f5d5ff0710ef2509743e Mon Sep 17 00:00:00 2001 From: Perry Lee Date: Tue, 6 Feb 2024 17:20:52 -0800 Subject: [PATCH 1/2] Add Docker file --- Dockerfile | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 Dockerfile diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 00000000..25b229ab --- /dev/null +++ b/Dockerfile @@ -0,0 +1,21 @@ +FROM nvidia/cuda:11.2.2-runtime-ubuntu20.04 + +RUN apt-get update --yes --quiet +RUN apt install software-properties-common -y && add-apt-repository ppa:deadsnakes/ppa -y && \ + apt-get install -y python3.10 \ + pip \ + python3.10-distutils \ + curl + +RUN curl -sS https://bootstrap.pypa.io/get-pip.py | python3.10 +RUN python3.10 -m pip install -U pip + +WORKDIR /app + +COPY requirements.txt /app + +RUN python3.10 -m pip install -r requirements.txt + +COPY . /app + +CMD python3.10 server_vllm.py --model "meetkai/functionary-small-v2.2" --host 0.0.0.0 From a6159ff6bc695edc7557f1f2822e0c3868bedb23 Mon Sep 17 00:00:00 2001 From: Perry Lee Date: Tue, 6 Feb 2024 17:25:54 -0800 Subject: [PATCH 2/2] Add Docker commands in README.md --- README.md | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/README.md b/README.md index 2fa6b55f..083ba721 100644 --- a/README.md +++ b/README.md @@ -26,6 +26,15 @@ Now you can start a blazing fast [vLLM](https://vllm.readthedocs.io/en/latest/ge python3 server_vllm.py --model "meetkai/functionary-small-v2.2" --host 0.0.0.0 ``` +#### Run in Docker + +You can also run functionary in Docker + +```shell +docker build . -t functionary +docker run -p 8000:8000 functionary +``` + ### OpenAI Compatible Usage ```python