-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathDockerfile.articutool
50 lines (38 loc) · 1.59 KB
/
Dockerfile.articutool
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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
FROM ros2_humble_base:latest
ENV ROS_DOMAIN_ID=42
# Install ROS2 control and other dependencies
RUN apt-get update && apt-get install -y \
ros-humble-ros2-control \
ros-humble-ros2-controllers \
ros-humble-controller-manager \
ros-humble-joint-state-publisher \
ros-humble-joint-trajectory-controller \
ros-humble-diff-drive-controller \
ros-humble-xacro \
ros-humble-joint-state-publisher-gui \
ros-humble-dynamixel-sdk \
ros-humble-dynamixel-workbench-toolbox \
ros-humble-pinocchio \
ros-humble-tf-transformations \
&& rm -rf /var/lib/apt/lists/*
# Install Python dependencies with pip
RUN pip3 install pinocchio pyserial numpy scipy matplotlib filterpy
# Create Articutool workspace directory
RUN mkdir -p /articutool_ws/src
# Clone Articutool repository(s)
RUN git clone https://github.com/personalrobotics/articutool_ros2.git && \
mv articutool_ros2 /articutool_ws/src/
# Update rosdep and apt repositories
RUN rosdep update && apt-get update
# Install Articutool dependencies with rosdep
RUN rosdep install --from-paths /articutool_ws/src --ignore-src -r -y --rosdistro humble
# Build Articutool workspace
RUN bash -c "source /opt/ros/humble/setup.bash && cd /articutool_ws && colcon build --symlink-install"
# Source Articutool setup
RUN echo "source /articutool_ws/install/setup.bash" >> /root/.bashrc
# Set the working directory
WORKDIR /articutool_ws
# Install Python dependencies from requirements.txt
RUN pip install --no-cache-dir -r src/articutool_ros2/requirements.txt
# Set the entry point
CMD ["/bin/bash", "-c", "source /root/.bashrc && bash"]