Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ros naming #473

Merged
merged 6 commits into from
Jul 15, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 12 additions & 12 deletions .docker/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -8,27 +8,30 @@ ARG BASE_BRANCH=

######################### Base Tutorial Image #################################################

FROM moveit/moveit2:${ROS_DISTRO}-source as base_image

FROM ros:${ROS_DISTRO}-ros-base as base_image
ENV ROS_UNDERLAY /root/ws_moveit/
WORKDIR $ROS_UNDERLAY

# Copy MoveIt sources from docker context
COPY . src/moveit2_tutorials

# Commands are combined in single RUN statement with "apt/lists" folder removal to reduce image size
# https://docs.docker.com/develop/develop-images/dockerfile_best-practices/#minimize-the-number-of-layers
RUN --mount=type=cache,target=/root/.ccache/ \
# Enable ccache
PATH=/usr/lib/ccache:$PATH && \
# Fetch required upstream sources for building
vcs import src < /root/ws_moveit/src/moveit2_tutorials/moveit2_tutorials.repos && \
. "/opt/ros/${ROS_DISTRO}/setup.sh" &&\
. "install/setup.sh" &&\
sudo apt update && rosdep install -r --from-paths src --ignore-src --rosdistro $ROS_DISTRO -y && \
colcon build \
--cmake-args -DCMAKE_BUILD_TYPE=Release -DBUILD_TESTING=OFF -DCMAKE_EXPORT_COMPILE_COMMANDS=ON \
--ament-cmake-args -DCMAKE_BUILD_TYPE=Debug \
--event-handlers desktop_notification- status- && \
ccache -s && \
# Update /ros_entrypoint.sh to source our new workspace
sed -i "s#/opt/ros/\$ROS_DISTRO/setup.bash#$ROS_UNDERLAY/setup.bash#g" /ros_entrypoint.sh
--event-handlers desktop_notification- status-

# Update /ros_entrypoint.sh to source our new workspace
RUN sed -i "s#/opt/ros/\$ROS_DISTRO/setup.bash#$ROS_UNDERLAY/install/setup.bash#g" /ros_entrypoint.sh

######################### Hello World Tutorial Image #########################################

Expand All @@ -54,8 +57,7 @@ RUN --mount=type=cache,target=/root/.ccache/ \
colcon build \
--cmake-args -DCMAKE_BUILD_TYPE=Release -DBUILD_TESTING=OFF -DCMAKE_EXPORT_COMPILE_COMMANDS=ON \
--ament-cmake-args -DCMAKE_BUILD_TYPE=Debug \
--event-handlers desktop_notification- status- && \
ccache -s
--event-handlers desktop_notification- status-

######################### Planning Around Objects Image #######################################

Expand All @@ -72,8 +74,7 @@ RUN --mount=type=cache,target=/root/.ccache/ \
colcon build \
--cmake-args -DCMAKE_BUILD_TYPE=Release -DBUILD_TESTING=OFF -DCMAKE_EXPORT_COMPILE_COMMANDS=ON \
--ament-cmake-args -DCMAKE_BUILD_TYPE=Debug \
--event-handlers desktop_notification- status- && \
ccache -s
--event-handlers desktop_notification- status-

######################### Pick and Place (MTC) Image #########################################

Expand Down Expand Up @@ -103,5 +104,4 @@ RUN --mount=type=cache,target=/root/.ccache/ \
colcon build \
--cmake-args -DCMAKE_BUILD_TYPE=Release -DBUILD_TESTING=OFF -DCMAKE_EXPORT_COMPILE_COMMANDS=ON \
--ament-cmake-args -DCMAKE_BUILD_TYPE=Debug \
--event-handlers desktop_notification- status- && \
ccache -s
--event-handlers desktop_notification- status-
1 change: 0 additions & 1 deletion .github/workflows/docker-base.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@ jobs:
if: steps.changed-files.outputs.any_changed == 'true'
uses: docker/setup-buildx-action@v2
- name: Login to Github Container Registry
if: steps.changed-files.outputs.any_changed == 'true'
uses: docker/login-action@v2
with:
registry: ghcr.io
Expand Down
1 change: 0 additions & 1 deletion .github/workflows/docker-images.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@ jobs:
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2
- name: Login to Github Container Registry
if: env.PUSH == 'true'
uses: docker/login-action@v2
with:
registry: ghcr.io
Expand Down