Skip to content

Commit

Permalink
Added buildable docker, finally
Browse files Browse the repository at this point in the history
  • Loading branch information
fzoric8 committed Jun 4, 2024
1 parent f45c02b commit c0dfa24
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 7 deletions.
31 changes: 24 additions & 7 deletions ros2/humble/kinova/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -123,24 +123,41 @@ RUN echo "export RMW_IMPLEMENTATION=rmw_cyclonedds_cpp" >> ~/.bashrc
WORKDIR ${COLCON_WS}
RUN sudo apt install ros-${ROS2_DISTRO}-ament-cmake-python
RUN sudo apt-get install ros-${ROS2_DISTRO}-rviz-visual-tools
RUN bash -c "source /opt/ros/humble/setup.sh; source ~/.bashrc; MAKEFLAGS="-j{nproc-1}" colcon build --event-handlers desktop_notification- status- --cmake-args -DCMAKE_BUILD_TYPE=Release"
RUN bash -c "source /opt/ros/humble/setup.sh; source ~/.bashrc; MAKEFLAGS="-j${nproc-1}" colcon build --event-handlers desktop_notification- status- --cmake-args -DCMAKE_BUILD_TYPE=Release"
WORKDIR ${COLCON_WS}/src
RUN git clone https://github.com/moveit/moveit2_tutorials.git -b ${ROS2_DISTRO}
RUN git clone https://github.com/moveit/moveit_visual_tools.git -b ros2
RUN git clone https://github.com/PickNikRobotics/graph_msgs.git -b ros2
WORKDIR ${COLCON_WS}
RUN bash -c "source /opt/ros/humble/setup.sh; source ~/.bashrc; MAKEFLAGS="-j{nproc-1}" colcon build --event-handlers desktop_notification- status- --cmake-args -DCMAKE_BUILD_TYPE=Release"
RUN bash -c "source /opt/ros/humble/setup.sh; source ~/.bashrc; MAKEFLAGS="-j${nproc-1}" colcon build --event-handlers desktop_notification- status- --cmake-args -DCMAKE_BUILD_TYPE=Release"
RUN echo "source ${COLCON_WS}/install/setup.bash" >> ~/.bashrc

# Create ros2_kortex repository
WORKDIR /root
#RUN apt-get update
#RUN apt-get install python3-pip -y
#RUN pip install git+https://github.com/catkin/catkin_tools.git
# RUN apt-get install -y python3-catkin-tools
#WORKDIR /root
#RUN git clone https://github.com/tylerjw/serial.git
#WORKDIR /root/serial
#RUN mkdir build
#WORKDIR /root/serial/build
#RUN cmake ..
#RUN make
#RUN make install

#RUN apt-get install -y libserial-dev
RUN mkdir -p kortex2_ws/src
WORKDIR /root/kortex2_ws/src
RUN git clone https://github.com/PickNikRobotics/ros2_kortex.git
RUN git clone https://github.com/tylerjw/serial.git --single-branch ros2
RUN git clone https://github.com/tylerjw/serial.git
WORKDIR /root/kortex2_ws/src/serial
RUN git checkout ros2
WORKDIR /root/kortex2_ws/src/
RUN git clone https://github.com/PickNikRobotics/ros2_robotiq_gripper.git
RUN rosdep install --ignore-src --from-paths src -y -r
RUN bash -c "source /opt/ros/humble/setup.bash; MAKEFLAGS="-j{nproc-1}" colcon build --cmake-args -DCMAKE_BUILD_TYPE=Release"
RUN git clone https://github.com/PickNikRobotics/ros2_kortex.git
WORKDIR /root/kortex2_ws
#RUN rosdep install --ignore-src --from-paths src -y -r
RUN bash -c "source /opt/ros/humble/setup.bash; colcon build"
RUN echo "source /root/kortex2_ws/install/setup.bash"

CMD ["bash"]
3 changes: 3 additions & 0 deletions ros2/humble/kinova/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,3 +34,6 @@ And after that:
`dev_ws`: is the workspace where we develop.


#### Possible issues:

- [ros2_robotiq_gripper](https://github.com/PickNikRobotics/ros2_robotiq_gripper/issues/21)

0 comments on commit c0dfa24

Please sign in to comment.