-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This version contains some general improvements and fixes, including support for the breaking changes introduced by control libraries 5.0
- Loading branch information
Showing
25 changed files
with
619 additions
and
407 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
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 |
---|---|---|
@@ -0,0 +1,16 @@ | ||
ARG ROS_VERSION=galactic | ||
FROM ghcr.io/aica-technology/ros2-control-libraries:${ROS_VERSION} as development | ||
|
||
WORKDIR ${HOME}/ros2_ws | ||
# copy sources and build ROS workspace with user permissions | ||
WORKDIR ${HOME}/ros2_ws/ | ||
COPY --chown=${USER} ./source/ ./src/ | ||
|
||
# clean image | ||
RUN sudo apt-get clean && sudo rm -rf /var/lib/apt/lists/* | ||
|
||
|
||
FROM development as production | ||
|
||
# build modulo | ||
RUN /bin/bash -c "source /opt/ros/$ROS_DISTRO/setup.bash; colcon build" |
This file was deleted.
Oops, something went wrong.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
#!/bin/bash | ||
ROS_VERSION=galactic | ||
|
||
IMAGE_NAME=epfl-lasa/modulo | ||
IMAGE_TAG=latest | ||
|
||
REMOTE_SSH_PORT=4440 | ||
SERVE_REMOTE=false | ||
|
||
HELP_MESSAGE="Usage: build.sh [-p] [-r] | ||
Options: | ||
-d, --development Only target the development layer to prevent | ||
sources from being built or tested | ||
-r, --rebuild Rebuild the image(s) using the docker | ||
--no-cache option | ||
-v, --verbose Use the verbose option during the building | ||
process | ||
-s, --serve Start the remove development server | ||
" | ||
|
||
BUILD_FLAGS=(--build-arg ROS_VERSION="${ROS_VERSION}") | ||
while [[ $# -gt 0 ]]; do | ||
opt="$1" | ||
case $opt in | ||
-d|--development) BUILD_FLAGS+=(--target development) ; IMAGE_TAG=development ; shift ;; | ||
-r|--rebuild) BUILD_FLAGS+=(--no-cache) ; shift ;; | ||
-v|--verbose) BUILD_FLAGS+=(--progress=plain) ; shift ;; | ||
-s|--serve) SERVE_REMOTE=true ; shift ;; | ||
-h|--help) echo "${HELP_MESSAGE}" ; exit 0 ;; | ||
*) echo 'Error in command line parsing' >&2 | ||
echo -e "\n${HELP_MESSAGE}" | ||
exit 1 | ||
esac | ||
done | ||
|
||
docker pull ghcr.io/aica-technology/ros2-control-libraries:"${ROS_VERSION}" | ||
DOCKER_BUILDKIT=1 docker build -t "${IMAGE_NAME}:${IMAGE_TAG}" "${BUILD_FLAGS[@]}" . || exit 1 | ||
|
||
if [ "${SERVE_REMOTE}" = true ]; then | ||
aica-docker server "${IMAGE_NAME}:${IMAGE_TAG}" -u ros2 -p "${REMOTE_SSH_PORT}" | ||
fi |
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
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
Oops, something went wrong.