Skip to content

Commit 5763a82

Browse files
committed
fixed the dockerfile issue
1 parent 54988b8 commit 5763a82

File tree

2 files changed

+13
-6
lines changed

2 files changed

+13
-6
lines changed

.ci/docker/centos-rocm/Dockerfile

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -101,10 +101,13 @@ COPY ./common/install_cache.sh install_cache.sh
101101
ENV PATH /opt/cache/bin:$PATH
102102
RUN bash ./install_cache.sh && rm install_cache.sh
103103

104+
WORKDIR /app
105+
RUN apt-get update && apt-get install -y git python3 python3-pip python3-setuptools
104106
RUN git clone https://github.com/ROCm/rocm-libraries.git
105-
RUN cd rocm-libraries/shared/origami/python
106-
RUN python setup.py build_ext --inplace
107-
RUN export PYTHONPATH=$(pwd):$PYTHONPATH
107+
RUN pip install nanobind
108+
WORKDIR /app/rocm-libraries/shared/origami/python
109+
RUN python3 setup.py build_ext --inplace
110+
ENV PYTHONPATH=/app/rocm-libraries/shared/origami/python:$PYTHONPATH
108111

109112
# Include BUILD_ENVIRONMENT environment variable in image
110113
ARG BUILD_ENVIRONMENT

.ci/docker/ubuntu-rocm/Dockerfile

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -133,10 +133,14 @@ COPY ./common/install_openmpi.sh install_openmpi.sh
133133
RUN if [ -n "${CUDA_VERSION}" ]; then bash install_openmpi.sh; fi
134134
RUN rm install_openmpi.sh
135135

136+
137+
WORKDIR /app
138+
RUN apt-get update && apt-get install -y git python3 python3-pip python3-setuptools
136139
RUN git clone https://github.com/ROCm/rocm-libraries.git
137-
RUN cd rocm-libraries/shared/origami/python
138-
RUN python setup.py build_ext --inplace
139-
RUN export PYTHONPATH=$(pwd):$PYTHONPATH
140+
RUN pip install nanobind
141+
WORKDIR /app/rocm-libraries/shared/origami/python
142+
RUN python3 setup.py build_ext --inplace
143+
ENV PYTHONPATH=/app/rocm-libraries/shared/origami/python:$PYTHONPATH
140144

141145
# Include BUILD_ENVIRONMENT environment variable in image
142146
ARG BUILD_ENVIRONMENT

0 commit comments

Comments
 (0)