Skip to content

Commit

Permalink
Use Zenoh instead of cycloneDDS
Browse files Browse the repository at this point in the history
  • Loading branch information
LoyVanBeek committed Dec 18, 2024
1 parent 785ae3b commit cfd1556
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 6 deletions.
20 changes: 15 additions & 5 deletions docker/operator/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,26 @@ ARG ROS_DISTRO=jazzy
FROM ros:${ROS_DISTRO}-ros-base

RUN apt update && apt-get install -y --no-install-recommends \
ros-${ROS_DISTRO}-rmw-cyclonedds-cpp \
ros-${ROS_DISTRO}-desktop \
iproute2 \
net-tools \
&& rm -rf /var/lib/apt/lists/*

# Prepare CycloneDDS config file
COPY ./docker/operator/cyclonedds.xml /cyclonedds.xml
ENV CYCLONEDDS_URI=file:///cyclonedds.xml
ENV RMW_IMPLEMENTATION=rmw_cyclonedds_cpp
RUN mkdir -p /root/ros2_ws/src
WORKDIR /root/ros2_ws/src
# Install rmw_zenoh
# Latest version as of writing
RUN git clone https://github.com/ros2/rmw_zenoh.git && cd rmw_zenoh && git reset --hard dd82e84 && cd ..

# Configure Zenoh
ENV RMW_IMPLEMENTATION=rmw_zenoh_cpp

WORKDIR /root/ros2_ws
RUN /bin/bash -c "source /opt/ros/${ROS_DISTRO}/setup.bash \
&& apt-get update -y \
&& rosdep install --from-paths src --ignore-src --rosdistro ${ROS_DISTRO} -y \
&& colcon build --symlink-install --event-handlers console_cohesion+\
&& rm -rf /var/lib/apt/lists/*"

# Set up entrypoint
COPY ./docker/operator/entrypoint.sh /
Expand Down
1 change: 0 additions & 1 deletion docker/robot/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,6 @@ WORKDIR /root/ros2_ws/src
# install ROS additional packages needed for application
RUN apt update -qq && apt install -y --no-install-recommends \
ros-${ROS_DISTRO}-xacro \
ros-${ROS_DISTRO}-rmw-cyclonedds-cpp \
ros-${ROS_DISTRO}-teleop-twist-keyboard \
&& rm -rf /var/lib/apt/lists/*

Expand Down

0 comments on commit cfd1556

Please sign in to comment.