Skip to content

Commit 7610d19

Browse files
Update for ARM support (#229)
1 parent f5587de commit 7610d19

File tree

1 file changed

+10
-7
lines changed

1 file changed

+10
-7
lines changed

Dockerfile

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Copyright (c) 2020, NVIDIA CORPORATION. All rights reserved.
1+
# Copyright (c) 2020-2021, NVIDIA CORPORATION & AFFILIATES. All rights reserved.
22
#
33
# Licensed under the Apache License, Version 2.0 (the "License");
44
# you may not use this file except in compliance with the License.
@@ -36,17 +36,20 @@ RUN apt-get update && \
3636
RUN mkdir -p /opt/triton-model-analyzer
3737

3838
# Install DCGM
39-
RUN apt-get update && apt-get install -y --no-install-recommends software-properties-common && \
40-
wget https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2004/x86_64/cuda-ubuntu2004.pin && \
39+
ARG TARGETARCH
40+
RUN if [ "${TARGETARCH}" = "amd64" ] ; then ARCH_DIR="x86_64" ; fi ; \
41+
if [ "${TARGETARCH}" = "arm64" ] ; then ARCH_DIR="sbsa" ; fi ; \
42+
apt-get update && apt-get install -y --no-install-recommends software-properties-common && \
43+
wget https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2004/${ARCH_DIR}/cuda-ubuntu2004.pin && \
4144
mv cuda-ubuntu2004.pin /etc/apt/preferences.d/cuda-repository-pin-600 && \
42-
apt-key adv --fetch-keys https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2004/x86_64/7fa2af80.pub && \
43-
add-apt-repository "deb https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2004/x86_64/ /" && \
45+
apt-key adv --fetch-keys https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2004/${ARCH_DIR}/7fa2af80.pub && \
46+
add-apt-repository "deb https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2004/${ARCH_DIR}/ /" && \
4447
apt-get install -y datacenter-gpu-manager=1:${DCGM_VERSION}
4548

4649
# Install tritonclient
4750
COPY --from=sdk /workspace/install/python /tmp/tritonclient
4851
RUN find /tmp/tritonclient -maxdepth 1 -type f -name \
49-
"tritonclient-*-manylinux1_x86_64.whl" | xargs printf -- '%s[all]' | \
52+
"tritonclient-*-manylinux*.whl" | xargs printf -- '%s[all]' | \
5053
xargs pip3 install --upgrade && rm -rf /tmp/tritonclient/
5154

5255
WORKDIR /opt/triton-model-analyzer
@@ -61,7 +64,7 @@ RUN chmod +x build_wheel.sh && \
6164
rm -f perf_analyzer
6265
RUN python3 -m pip install --upgrade pip && \
6366
python3 -m pip install nvidia-pyindex && \
64-
python3 -m pip install wheels/triton_model_analyzer-*-manylinux1_x86_64.whl
67+
python3 -m pip install wheels/triton_model_analyzer-*-manylinux*.whl
6568

6669
RUN apt-get install -y wkhtmltopdf
6770

0 commit comments

Comments
 (0)