Skip to content

Commit

Permalink
test docker
Browse files Browse the repository at this point in the history
  • Loading branch information
Ying1123 committed Aug 3, 2024
1 parent b906c01 commit 5b05f1b
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 5 deletions.
3 changes: 3 additions & 0 deletions .github/workflows/release-docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@ jobs:
matrix:
cuda_version: ['12.1.1', '12.4.1']
steps:
- name: Delete huge unnecessary tools folder
run: rm -rf /opt/hostedtoolcache

- name: Checkout repository
uses: actions/checkout@v3

Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,8 @@ pip install flashinfer -i https://flashinfer.ai/whl/cu121/torch2.3/

### Method 2: From source
```
# Use the stable v0.2.9.post1 branch
git clone -b v0.2.9.post1 https://github.com/sgl-project/sglang.git
# Use the stable v0.2.9.post2 branch
git clone -b v0.2.9.post2 https://github.com/sgl-project/sglang.git
cd sglang
pip install --upgrade pip
Expand Down
8 changes: 5 additions & 3 deletions docker/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
ARG CUDA_VERSION=12.1.1

FROM nvidia/cuda:${CUDA_VERSION}-devel-ubuntu22.04
FROM nvidia/cuda:${CUDA_VERSION}-devel-ubuntu20.04

ARG PYTHON_VERSION=3

Expand All @@ -12,7 +12,7 @@ RUN echo 'tzdata tzdata/Areas select America' | debconf-set-selections \
&& apt-get install -y ccache software-properties-common \
&& add-apt-repository ppa:deadsnakes/ppa \
&& apt-get update -y \
&& apt-get install -y python${PYTHON_VERSION} python${PYTHON_VERSION}-dev python${PYTHON_VERSION}-venv python3-pip \
&& apt-get install -y python${PYTHON_VERSION} python${PYTHON_VERSION}-dev python${PYTHON_VERSION}-venv python${PYTHON_VERSION}-pip \
&& if [ "${PYTHON_VERSION}" != "3" ]; then update-alternatives --install /usr/bin/python3 python3 /usr/bin/python${PYTHON_VERSION} 1; fi \
&& python3 --version \
&& python3 -m pip --version \
Expand All @@ -25,9 +25,11 @@ RUN apt-get update -y \
WORKDIR /sgl-workspace

RUN pip3 --no-cache-dir install --upgrade pip \
&& pip3 --no-cache-dir install --upgrade setuptools wheel \
&& python3 -m pip install --upgrade --user pip \
&& git clone --depth=1 https://github.com/sgl-project/sglang.git \
&& cd sglang \
&& pip3 --no-cache-dir install -e "python[all]" \
&& pip --no-cache-dir install -e "python[all]" \
&& pip3 --no-cache-dir install flashinfer -i https://flashinfer.ai/whl/cu121/torch2.3/

ENV DEBIAN_FRONTEND=interactive

0 comments on commit 5b05f1b

Please sign in to comment.