-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dockerfile.receive
36 lines (28 loc) · 1.23 KB
/
Dockerfile.receive
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
# Use an Ubuntu 20.04 base image compatible with ARM architectures
FROM ubuntu:20.04
# Avoid prompts from apt
ENV DEBIAN_FRONTEND=noninteractive
# Update and install necessary packages
RUN apt-get update && apt-get install -y \
curl \
gnupg2 \
lsb-release \
&& rm -rf /var/lib/apt/lists/*
# Add the ROS repository
RUN sh -c 'echo "deb http://packages.ros.org/ros/ubuntu $(lsb_release -sc) main" > /etc/apt/sources.list.d/ros-latest.list'
# Import the ROS key
RUN curl -s https://raw.githubusercontent.com/ros/rosdistro/master/ros.asc | apt-key add -
# Install ROS Noetic, the realsense2 camera package, and the RPLIDAR package
RUN apt-get update && apt-get install -y \
ros-noetic-ros-base \
ros-noetic-realsense2-camera \
ros-noetic-rplidar-ros \
python3-rosdep \
&& rm -rf /var/lib/apt/lists/*
# Initialize rosdep
RUN rosdep init \
&& rosdep update
# Setup the environment for all users and shell sessions
RUN echo "source /opt/ros/noetic/setup.bash" > /etc/profile.d/ros1_setup.sh
# Use bash as the default command to run rostopic echo on the specified RealSense topic with the --noarr flag
CMD ["/bin/bash", "-c", "source /opt/ros/noetic/setup.bash && rostopic echo --noarr /rgbd/camera/color/image/raw"]