-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathDockerfile
More file actions
24 lines (14 loc) · 850 Bytes
/
Dockerfile
File metadata and controls
24 lines (14 loc) · 850 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
ARG BASE_TAG=galactic
FROM ghcr.io/aica-technology/ros2-control-libraries:${BASE_TAG} as dependencies
WORKDIR ${HOME}/ros2_ws
FROM dependencies as modulo-component-interfaces
COPY --chown=${USER} ./source/modulo_component_interfaces ./src/modulo_component_interfaces
RUN /bin/bash -c "source /opt/ros/$ROS_DISTRO/setup.bash; colcon build"
FROM modulo-component-interfaces as modulo-core
COPY --chown=${USER} ./source/modulo_core ./src/modulo_core
RUN /bin/bash -c "source /opt/ros/$ROS_DISTRO/setup.bash; colcon build --packages-select modulo_core"
FROM modulo-core as modulo-components
COPY --chown=${USER} ./source/modulo_components ./src/modulo_components
RUN /bin/bash -c "source /opt/ros/$ROS_DISTRO/setup.bash; colcon build --packages-select modulo_components"
# clean image
RUN sudo apt-get clean && sudo rm -rf /var/lib/apt/lists/*