Update Dockerfile
Splitting in more layers. Rearranging
This commit is contained in:
parent
958a0c70ef
commit
e3f484edb4
@ -45,8 +45,9 @@ WORKDIR /rmp_ws
|
|||||||
RUN source /opt/ros/${ROS_DISTRO}/setup.bash \
|
RUN source /opt/ros/${ROS_DISTRO}/setup.bash \
|
||||||
&& apt-get update -y \
|
&& apt-get update -y \
|
||||||
&& rosdep install --from-paths src --ignore-src --rosdistro ${ROS_DISTRO} -y \
|
&& rosdep install --from-paths src --ignore-src --rosdistro ${ROS_DISTRO} -y \
|
||||||
&& colcon build --symlink-install \
|
|
||||||
&& rm -rf /var/lib/apt/lists/*
|
RUN source /opt/ros/${ROS_DISTRO}/setup.bash \
|
||||||
|
&& colcon build --symlink-install
|
||||||
|
|
||||||
# Use Cyclone DDS as middleware
|
# Use Cyclone DDS as middleware
|
||||||
RUN apt-get update && apt-get install -y --no-install-recommends \
|
RUN apt-get update && apt-get install -y --no-install-recommends \
|
||||||
@ -72,11 +73,14 @@ RUN vcs import < overlay.repos
|
|||||||
WORKDIR /overlay_ws
|
WORKDIR /overlay_ws
|
||||||
|
|
||||||
RUN source /rmp_ws/install/setup.bash \
|
RUN source /rmp_ws/install/setup.bash \
|
||||||
&& colcon build --symlink-install \
|
|
||||||
&& apt-get update \
|
&& apt-get update \
|
||||||
&& rosdep install --from-paths src --ignore-src --rosdistro ${ROS_DISTRO} -y \
|
&& rosdep install --from-paths src --ignore-src --rosdistro ${ROS_DISTRO} -y \
|
||||||
&& rm -rf /var/lib/apt/lists/*
|
&& rm -rf /var/lib/apt/lists/*
|
||||||
|
|
||||||
|
|
||||||
|
RUN source /rmp_ws/install/setup.bash \
|
||||||
|
&& colcon build --symlink-install
|
||||||
|
|
||||||
# Set up the entrypoint
|
# Set up the entrypoint
|
||||||
COPY ./docker/entrypoint.sh /
|
COPY ./docker/entrypoint.sh /
|
||||||
RUN chmod +x /entrypoint.sh
|
RUN chmod +x /entrypoint.sh
|
||||||
@ -96,13 +100,15 @@ FROM overlay AS guis
|
|||||||
|
|
||||||
# Install additional GUI tools
|
# Install additional GUI tools
|
||||||
RUN source /rmp_ws/install/setup.bash \
|
RUN source /rmp_ws/install/setup.bash \
|
||||||
&& colcon build --symlink-install \
|
|
||||||
&& apt-get update \
|
&& apt-get update \
|
||||||
&& apt-get install -y --no-install-recommends ros-${ROS_DISTRO}-rviz2 \
|
&& apt-get install -y --no-install-recommends ros-${ROS_DISTRO}-rviz2 \
|
||||||
&& rosdep install --from-paths src --ignore-src --rosdistro ${ROS_DISTRO} -y \
|
&& rosdep install --from-paths src --ignore-src --rosdistro ${ROS_DISTRO} -y \
|
||||||
&& rm -rf /var/lib/apt/lists/*
|
&& rm -rf /var/lib/apt/lists/*
|
||||||
|
|
||||||
|
RUN source /rmp_ws/install/setup.bash \
|
||||||
|
&& colcon build --symlink-install \
|
||||||
|
|
||||||
# Set up the entrypoint
|
# Set up the entrypoint
|
||||||
ENTRYPOINT [ "/entrypoint.sh" ]
|
ENTRYPOINT [ "/entrypoint.sh" ]
|
||||||
|
|
||||||
LABEL org.opencontainers.image.source=https://github.com/bjoernellens1/ros2_rmp
|
LABEL org.opencontainers.image.source=https://github.com/bjoernellens1/ros2_rmp
|
||||||
|
Loading…
Reference in New Issue
Block a user