Skip to content

Commit 1bc43a4

Browse files
committed
fix docker.tensorrt
1 parent 37773cd commit 1bc43a4

File tree

2 files changed

+4
-20
lines changed

2 files changed

+4
-20
lines changed

yolox_ros_cpp/docker/tensorrt/docker-compose.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@ services:
1717
capabilities: [gpu]
1818
environment:
1919
- DISPLAY=$DISPLAY
20+
- NVIDIA_DISABLE_REQUIRE=1
2021
volumes:
2122
- $HOME/ros2_ws:/root/ros2_ws
2223
- /tmp/.X11-unix:/tmp/.X11-unix

yolox_ros_cpp/docker/tensorrt/dockerfile

Lines changed: 3 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -17,28 +17,14 @@ ENV DEBIAN_FRONTEND=noninteractive
1717

1818
# Install basic dependencies
1919
RUN apt-get update
20-
RUN apt install -y build-essential manpages-dev wget zlib1g software-properties-common git libssl-dev zlib1g-dev libbz2-dev libreadline-dev libsqlite3-dev wget ca-certificates curl llvm libncurses5-dev xz-utils tk-dev libxml2-dev libxmlsec1-dev libffi-dev liblzma-dev mecab-ipadic-utf8
21-
22-
# Install PyEnv and desired Python version
23-
ENV HOME="/root"
24-
ENV PYENV_DIR="$HOME/.pyenv"
25-
ENV PATH="$PYENV_DIR/shims:$PYENV_DIR/bin:$PATH"
26-
RUN wget -L https://github.com/pyenv/pyenv-installer/raw/master/bin/pyenv-installer &&\
27-
chmod 755 pyenv-installer &&\
28-
bash pyenv-installer &&\
29-
eval "$(pyenv init -)"
30-
31-
RUN pyenv install -v ${PYTHON_VERSION}
32-
RUN pyenv global ${PYTHON_VERSION}
20+
RUN apt install -y build-essential manpages-dev wget zlib1g software-properties-common git libssl-dev zlib1g-dev libbz2-dev libreadline-dev libsqlite3-dev ca-certificates curl llvm libncurses5-dev xz-utils tk-dev libxml2-dev libxmlsec1-dev libffi-dev liblzma-dev mecab-ipadic-utf8
3321

3422
# Install TensorRT + dependencies
3523
RUN apt-key adv --fetch-keys https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2404/x86_64/3bf863cc.pub
3624
RUN add-apt-repository "deb https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2404/x86_64/ /"
3725
RUN apt-get update
3826
RUN TENSORRT_MAJOR_VERSION=`echo ${TENSORRT_VERSION} | cut -d '.' -f 1` && apt-get install -y tensorrt
3927

40-
ENV DEBIAN_FRONTEND=noninteractive
41-
4228
RUN apt update && apt install locales && \
4329
locale-gen en_US en_US.UTF-8 && \
4430
update-locale LC_ALL=en_US.UTF-8 LANG=en_US.UTF-8 && \
@@ -47,14 +33,13 @@ RUN apt update && apt install locales && \
4733
ENV LANG=en_US.UTF-8
4834

4935
RUN apt update && \
50-
apt install -y git wget curl gnupg2 lsb-release && \
36+
apt install -y git wget curl gnupg2 lsb-release
5137

5238
RUN curl -sSL https://raw.githubusercontent.com/ros/rosdistro/master/ros.key -o /usr/share/keyrings/ros-archive-keyring.gpg && \
5339
echo "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/ros-archive-keyring.gpg] http://packages.ros.org/ros2/ubuntu $(lsb_release -cs) main" | tee /etc/apt/sources.list.d/ros2.list > /dev/null && \
5440
sed -i -e 's/ubuntu .* main/ubuntu noble main/g' /etc/apt/sources.list.d/ros2.list && \
5541
apt update && \
56-
apt install -y openvino-2024.2.0 \
57-
ros-dev-tools \
42+
apt install -y ros-dev-tools \
5843
ros-jazzy-cv-bridge \
5944
ros-jazzy-generate-parameter-library \
6045
ros-jazzy-parameter-traits \
@@ -67,5 +52,3 @@ RUN curl -sSL https://raw.githubusercontent.com/ros/rosdistro/master/ros.key -o
6752

6853
COPY ./ros_entrypoint.sh /ros_entrypoint.sh
6954
RUN echo "source /ros_entrypoint.sh" >> /root/.bashrc
70-
# ENTRYPOINT ["/ros_entrypoint.sh"]
71-
CMD ["bash"]

0 commit comments

Comments
 (0)