Skip to content

Commit

Permalink
fix docker build
Browse files Browse the repository at this point in the history
  • Loading branch information
leasunhy committed Jun 23, 2024
1 parent 89fcb4b commit 53e193e
Show file tree
Hide file tree
Showing 3 changed files with 47 additions and 5 deletions.
23 changes: 22 additions & 1 deletion .github/workflows/docker_rdma.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,28 @@ jobs:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
-
name: Build and push cu117 with rdma
name: Free Disk Space (Ubuntu)
uses: jlumbroso/free-disk-space@main
with:
# this might remove tools that are actually needed,
# if set to "true" but frees about 6 GB
tool-cache: false

# all of these default to true, but feel free to set to
# "false" if necessary for your workflow
android: true
dotnet: true
haskell: true
large-packages: true
docker-images: false
swap-storage: false
-
name: Set up swap space
uses: pierotofy/set-swap-space@v1.0
with:
swap-size-gb: 10
-
name: Build and push with rdma (nightly)
uses: docker/build-push-action@v3
with:
context: ./docker/rdma/
Expand Down
25 changes: 23 additions & 2 deletions .github/workflows/docker_rdma_latest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ on:

jobs:
docker:
runs-on: self-hosted
runs-on: ubuntu-latest
steps:
-
name: Checkout
Expand All @@ -26,7 +26,28 @@ jobs:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
-
name: Build and push cu12.4 with rdma
name: Free Disk Space (Ubuntu)
uses: jlumbroso/free-disk-space@main
with:
# this might remove tools that are actually needed,
# if set to "true" but frees about 6 GB
tool-cache: false

# all of these default to true, but feel free to set to
# "false" if necessary for your workflow
android: true
dotnet: true
haskell: true
large-packages: true
docker-images: false
swap-storage: false
-
name: Set up swap space
uses: pierotofy/set-swap-space@v1.0
with:
swap-size-gb: 10
-
name: Build and push with rdma (nightly)
uses: docker/build-push-action@v3
with:
context: ./docker/rdma/
Expand Down
4 changes: 2 additions & 2 deletions docker/rdma/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ RUN APT_INSTALL="apt-get install -y --no-install-recommends" && \
# # ------------------------------------------------------------------
ENV TORCH_CUDA_ARCH_LIST "7.0;7.5;8.0;9.0"

RUN pip3 install --upgrade sentry-sdk requests
RUN pip3 install --no-cache-dir --upgrade sentry-sdk requests ninja typing packaging && rm -rf ~/.cache/pip

RUN cd /tmp && \
git clone https://github.com/dptech-corp/Uni-Core && \
Expand All @@ -66,7 +66,7 @@ RUN cd /tmp && \

RUN pip3 install --no-cache-dir tokenizers lmdb biopython ml-collections timeout-decorator urllib3 tree dm-tree && rm -rf ~/.cache/pip

RUN MAX_JOBS=4 pip3 install -U 'flash-attn<2.5.0' --no-build-isolation --no-cache-dir
RUN MAX_JOBS=1 pip3 install -U 'flash-attn<2.5.0' --no-build-isolation --no-cache-dir

RUN ldconfig && \
apt-get clean && \
Expand Down

0 comments on commit 53e193e

Please sign in to comment.