Skip to content

Commit 76a876b

Browse files
authored
Add workaround for ros apt source in Dockerfile.traffic_simulator
1 parent 5aa7552 commit 76a876b

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

Dockerfile.traffic_simulator

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,18 @@ SHELL ["/bin/bash", "-c"]
44
ENV DEBIAN_FRONTEND=noninteractive
55
ENV DEBCONF_NOWARNINGS=yes
66

7+
# workaround until the fix release in the official ros image
8+
RUN rm /etc/apt/sources.list.d/ros2-latest.list \
9+
&& rm /usr/share/keyrings/ros2-latest-archive-keyring.gpg
10+
RUN apt-get update \
11+
&& apt-get install -y ca-certificates curl
12+
13+
RUN export ROS_APT_SOURCE_VERSION=$(curl -s https://api.github.com/repos/ros-infrastructure/ros-apt-source/releases/latest | grep -F "tag_name" | awk -F\" '{print $4}') ;\
14+
curl -L -s -o /tmp/ros2-apt-source.deb "https://github.com/ros-infrastructure/ros-apt-source/releases/download/${ROS_APT_SOURCE_VERSION}/ros2-apt-source_${ROS_APT_SOURCE_VERSION}.$(. /etc/os-release && echo "$VERSION_CODENAME")_all.deb" \
15+
&& apt-get update \
16+
&& apt-get install -y /tmp/ros2-apt-source.deb \
17+
&& rm -f /tmp/ros2-apt-source.deb
18+
719
# cspell: ignore kisak
820
RUN --mount=type=cache,id=apt-cache-amd64,target=/var/cache/apt,sharing=locked \
921
--mount=type=cache,id=apt-lib-amd64,target=/var/lib/apt,sharing=locked \

0 commit comments

Comments
 (0)