Skip to content

Commit

Permalink
fixed
Browse files Browse the repository at this point in the history
  • Loading branch information
DerrickYLJ committed Jul 19, 2023
1 parent 1dcda17 commit 3ce77dc
Showing 1 changed file with 14 additions and 5 deletions.
19 changes: 14 additions & 5 deletions .github/workflows/docker-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -58,20 +58,29 @@ jobs:
# On push to inference, build for all compatible architectures, so that we can publish
# a pre-built general-purpose image. On all other cases, only build for one architecture
# to save time.
if [[ !( ( ${{ github.event_name }} == 'push' || ${{ github.event_name }} == 'schedule' ) && ${GITHUB_REF#refs/heads/} == "inference" ) && (( ${{ matrix.gpu_backend }} == "hip_rocm" || ${{ matrix.gpu_backend }} == "cuda") && (cuda_version == "11.8" )) ]]; then
export FF_CUDA_ARCH=70
./docker/build.sh flexflow
else
if [[ ( ( ${{ github.event_name }} == 'push' || ${{ github.event_name }} == 'schedule' ) && ${GITHUB_REF#refs/heads/} == "inference" ) ]]; then
export FF_CUDA_ARCH=all
./docker/build.sh flexflow
else
export FF_CUDA_ARCH=70
if [[ (( ${{ matrix.gpu_backend }} == "hip_rocm" || ${{ matrix.gpu_backend }} == "cuda") && (cuda_version == "11.8" )) ]]; then
./docker/build.sh flexflow
fi
fi
- name: Check availability of Python flexflow.core module
if: ${{ matrix.gpu_backend == 'cuda' }}
env:
cuda_version: ${{ matrix.cuda_version }}
run: docker run --env CPU_ONLY_TEST=1 --entrypoint /bin/bash flexflow-cuda-${cuda_version}:latest -c "export LD_LIBRARY_PATH=/usr/local/cuda/lib64/stubs:$LD_LIBRARY_PATH; sudo ln -s /usr/local/cuda/lib64/stubs/libcuda.so /usr/local/cuda/lib64/stubs/libcuda.so.1; python -c 'import flexflow.core; exit()'"
run: |
if [[ ( ( ${{ github.event_name }} == 'push' || ${{ github.event_name }} == 'schedule' ) && ${GITHUB_REF#refs/heads/} == "inference" ) ]]; then
docker run --env CPU_ONLY_TEST=1 --entrypoint /bin/bash flexflow-cuda-${cuda_version}:latest -c "export LD_LIBRARY_PATH=/usr/local/cuda/lib64/stubs:$LD_LIBRARY_PATH; sudo ln -s /usr/local/cuda/lib64/stubs/libcuda.so /usr/local/cuda/lib64/stubs/libcuda.so.1; python -c 'import flexflow.core; exit()'"
else
if [[ (( ${{ matrix.gpu_backend }} == "hip_rocm" || ${{ matrix.gpu_backend }} == "cuda") && (cuda_version == "11.8" )) ]]; then
docker run --env CPU_ONLY_TEST=1 --entrypoint /bin/bash flexflow-cuda-${cuda_version}:latest -c "export LD_LIBRARY_PATH=/usr/local/cuda/lib64/stubs:$LD_LIBRARY_PATH; sudo ln -s /usr/local/cuda/lib64/stubs/libcuda.so /usr/local/cuda/lib64/stubs/libcuda.so.1; python -c 'import flexflow.core; exit()'"
fi
fi
- name: Publish Docker environment image (on push to inference)
if: github.repository_owner == 'flexflow'
Expand Down

0 comments on commit 3ce77dc

Please sign in to comment.