Skip to content

Commit fc5a8eb

Browse files
[UX] Pre-build a EFA version of the default Docker image #2793
1 parent bcfc856 commit fc5a8eb

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

docker/base/base-efa.Dockerfile

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,10 +49,9 @@ RUN cd /tmp \
4949
--with-cuda=${CUDA_HOME} \
5050
--with-libfabric=${LIBFABRIC_PATH} \
5151
--with-mpi=${OPEN_MPI_PATH} \
52-
--with-nccl=${NCCL_HOME} \
5352
--disable-tests \
5453
--prefix=${NCCL_HOME} \
55-
&& make -j$(numproc) \
54+
&& make -j$(nproc) \
5655
&& make install
5756

5857
# Build NCCL
@@ -77,13 +76,17 @@ ENV NCCL_HOME=/opt/nccl
7776
ENV LIBFABRIC_PATH=/opt/amazon/efa
7877
ENV OPEN_MPI_PATH=/opt/amazon/openmpi
7978
ENV NCCL_TESTS_HOME=/opt/nccl-tests
79+
8080
ENV PATH="${LIBFABRIC_PATH}/bin:${OPEN_MPI_PATH}/bin:${PATH}"
81+
# TODO: Unsure if this is required, updating ` /etc/ld.so.conf.d` should be enough
8182
ENV LD_LIBRARY_PATH="${OPEN_MPI_PATH}/lib:${LD_LIBRARY_PATH}"
8283

8384
COPY --from=builder ${NCCL_HOME} ${NCCL_HOME}
8485
COPY --from=builder ${LIBFABRIC_PATH} ${LIBFABRIC_PATH}
8586
COPY --from=builder ${OPEN_MPI_PATH} ${OPEN_MPI_PATH}
8687
COPY --from=builder ${NCCL_TESTS_HOME}/build ${NCCL_TESTS_HOME}
88+
COPY --from=builder /etc/ld.so.conf.d/000_efa.conf /etc/ld.so.conf.d/000_efa.conf
89+
COPY --from=builder /etc/profile.d/zippy_efa.sh /etc/profile.d/zippy_efa.sh
8790

8891
RUN echo "${NCCL_HOME}/lib" >> /etc/ld.so.conf.d/nccl.conf \
8992
&& echo "${OPEN_MPI_PATH}/lib" >> /etc/ld.so.conf.d/openmpi.conf \

0 commit comments

Comments
 (0)