-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
12 changed files
with
27 additions
and
583 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,33 +1,21 @@ | ||
# fog-sw BUILDER | ||
ARG FROM_IMAGE | ||
FROM $FROM_IMAGE as fog-sw-builder | ||
ARG ROS_DISTRO="galactic" | ||
ARG UID=1000 | ||
ARG GID=1000 | ||
ARG PACKAGE_NAME | ||
|
||
WORKDIR /$PACKAGE_NAME/main_ws | ||
USER root | ||
ADD . /$PACKAGE_NAME/main_ws/src | ||
RUN chown -R builder:builder /$PACKAGE_NAME/main_ws | ||
|
||
USER builder | ||
|
||
RUN if [ -e /$PACKAGE_NAME/deps_ws ]; then \ | ||
. /$PACKAGE_NAME/deps_ws/install/setup.sh && \ | ||
colcon build; \ | ||
elif [ -e /opt/ros/${ROS_DISTRO}/setup.sh ]; then \ | ||
. /opt/ros/${ROS_DISTRO}/setup.sh && \ | ||
colcon build; \ | ||
fi | ||
|
||
RUN sed --in-place \ | ||
's|^source .*|source "/'$PACKAGE_NAME'/main_ws/install/setup.bash"|' \ | ||
/$PACKAGE_NAME/entrypoint.sh && \ | ||
chmod +x /$PACKAGE_NAME/entrypoint.sh | ||
|
||
ENV PACKAGE_NAME $PACKAGE_NAME | ||
ENV RMW_IMPLEMENTATION rmw_fastrtps_cpp | ||
|
||
WORKDIR /$PACKAGE_NAME | ||
ENTRYPOINT "/"$PACKAGE_NAME"/entrypoint.sh" | ||
FROM ghcr.io/tiiuae/fog-ros-baseimage:builder-latest AS builder | ||
|
||
COPY . /main_ws/src/ | ||
|
||
# this: | ||
# 1) builds the application | ||
# 2) packages the application as .deb in build_output/ | ||
|
||
# RUN /packaging/build-and-package-as-deb.sh -o build_output/ | ||
RUN /packaging/build.sh | ||
|
||
# ▲ runtime ──┐ | ||
# └── build ▼ | ||
|
||
FROM ghcr.io/tiiuae/fog-ros-baseimage:sha-d2cdcdb | ||
|
||
ENTRYPOINT exec ros-with-env ros2 launch mocap_pose mocap_pose.launch | ||
|
||
COPY --from=builder /main_ws/ros-*-mocap-pose_*_amd64.deb /mocap-pose.deb | ||
|
||
RUN dpkg -i /mocap-pose.deb && rm /mocap-pose.deb |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.