Skip to content

Commit b317717

Browse files
Applied necessary changes to docs and docker files for Jazzy (#270)
* Applied necessary changes to docs and docker files for Jazzy Signed-off-by: JesusSilvaUtrera <jsilvautrera@gmail.com> * Changed back the year of the docker files Signed-off-by: JesusSilvaUtrera <jsilvautrera@gmail.com> --------- Signed-off-by: JesusSilvaUtrera <jsilvautrera@gmail.com>
1 parent cc40fa5 commit b317717

File tree

9 files changed

+53
-54
lines changed

9 files changed

+53
-54
lines changed

.github/pull_request_template.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ Please remove the appropriate section.
33
For example, if this is a new feature, remove all sections except for the "New feature" section
44
55
If this is your first time opening a PR, be sure to check the contribution guide:
6-
https://github.com/Ekumen-OS/andino/blob/humble/CONTRIBUTING.md
6+
https://github.com/Ekumen-OS/andino/blob/jazzy/CONTRIBUTING.md
77
-->
88

99
# 🦟 Bug fix

.github/workflows/ci.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,14 +3,14 @@ name: colcon build & test
33
on:
44
push:
55
branches:
6-
- humble
6+
- jazzy
77
pull_request:
88
branches:
9-
- humble
9+
- jazzy
1010
workflow_dispatch:
1111

1212
env:
13-
ROS_DISTRO: humble
13+
ROS_DISTRO: jazzy
1414

1515
# Cancel previously running PR jobs
1616
concurrency:
@@ -22,7 +22,7 @@ jobs:
2222
name: Compile and test
2323
runs-on: ubuntu-latest
2424
container:
25-
image: ubuntu:22.04
25+
image: ubuntu:24.04
2626
steps:
2727
- uses: actions/checkout@v3
2828
- uses: ros-tooling/setup-ros@v0.7

README.md

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@
1010

1111
</div>
1212

13+
[**UNSTABLE BRANCH**]
14+
1315
Andino is a fully open-source diff drive robot designed for educational purposes and low-cost applications.
1416
It is fully integrated with ROS 2 and it is a great base platform to improve skills over the robotics field.
1517
With its open-source design, anyone can modify and customize the robot to suit their specific needs.
@@ -55,16 +57,16 @@ Visit [`andino_hardware`](./andino_hardware/) for assembly instructions.
5557

5658
### Platforms
5759

58-
- ROS 2: Humble Hawksbill
60+
- ROS 2: Jazzy Jalisco
5961
- OS:
60-
- Ubuntu 22.04 Jammy Jellyfish
61-
- Ubuntu Mate 22.04 (On real robot (e.g: Raspberry Pi 4B))
62+
- Ubuntu 24.04 Noble Numbat
63+
- Ubuntu Server 24.04.1 (WIP) (On real robot (e.g: Raspberry Pi 4B))
6264

6365
### Build from Source
6466

6567
#### Dependencies
6668

67-
1. Install [ROS 2](https://docs.ros.org/en/humble/Installation/Ubuntu-Install-Debians.html)
69+
1. Install [ROS 2](https://docs.ros.org/en/jazzy/Installation/Ubuntu-Install-Debs.html)
6870
2. Install [colcon](https://colcon.readthedocs.io/en/released/user/installation.html)
6971

7072
#### colcon workspace

andino_hardware/README.md

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -99,12 +99,12 @@ For uploading the microcontroller firmware please refer to [`andino_firmware`](.
9999

100100
The SBC used in this project is a Raspberry Pi 4b so the guidelines here will refer particularly to this family of on-board computers, however extending its use to other families is possible as well.
101101

102-
### Operative System
102+
### Operative System [WIP]
103103

104-
Ubuntu Mate 22.04 ARM64 is the recommended operative system for this project. This OS provides good capabilities for a educational platform as well as good performance.
104+
Ubuntu Server 24.04.1 is the recommended operative system for this project if you want to use the `jazzy` distro, since Ubuntu Mate 24 is not yet released.
105105

106106
For installing this OS in the Raspberry:
107-
1. Download the image from here: [ubuntu mate download](https://ubuntu-mate.org/download/arm64/)
107+
1. Download the image from here: [download Ubuntu 24 for Raspberry](https://ubuntu.com/download/raspberry-pi)
108108

109109

110110
2. Install OS to a microSD card using [Raspberry Pi Imager](https://www.raspberrypi.com/software/).
@@ -182,13 +182,6 @@ Configure it properly:
182182
sudo usermod -a -G plugdev $USER
183183
```
184184
Note you will need a reboot after this to be effective.
185-
2. Remove `brltty` from the system
186-
```
187-
sudo apt remove brltty
188-
```
189-
In Ubuntu 22.04 seems to be an issue with some chip drivers and the `brltty` daemon. To avoid this conflict we remove `brltty` as suggested. See [this stackoverflow post](https://stackoverflow.com/questions/70123431/why-would-ch341-uart-is-disconnected-from-ttyusb) for further information.
190-
191-
192185

193186
#### Raspberry Camera Module V2
194187

@@ -359,6 +352,8 @@ export ROS_DISTRO=humble
359352
```
360353
And then proceed to install the workspace dependencies:
361354
```
355+
sudo apt install python3-rosdep
356+
sudo rosdep init
362357
rosdep install --from-paths src -i -y -r
363358
```
364359
Note that option `-r` has been added. For ARM based processors, there are missing packages, e.g. those related to simulation. We would not try to run the simulation in the compute platform of andino, however for convenience it is added here.

docker/Dockerfile

Lines changed: 19 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,11 @@
1-
FROM osrf/ros:humble-desktop-full
1+
FROM osrf/ros:jazzy-desktop-full
22

33
# Arguments for building
4-
ARG USERID
5-
ARG USER
4+
ARG USER=ubuntu
65

76
# Setup environment
8-
ENV TERM linux
9-
ENV DEBIAN_FRONTEND noninteractive
7+
ENV TERM=linux
8+
ENV DEBIAN_FRONTEND=noninteractive
109
RUN echo 'debconf debconf/frontend select Noninteractive' | debconf-set-selections
1110

1211
# Copy requirement files and install dependencies
@@ -15,32 +14,37 @@ RUN apt-get update && apt-get install --no-install-recommends -y $(cat requireme
1514
RUN rm requirements.txt
1615

1716
# Create a user with passwordless sudo
18-
RUN adduser --uid $USERID --gecos "ekumen developer" --disabled-password $USER
19-
RUN adduser $USER sudo
2017
RUN echo '%sudo ALL=(ALL) NOPASSWD:ALL' >> /etc/sudoers
2118
RUN echo "export QT_X11_NO_MITSHM=1" >> /home/$USER/.bashrc
22-
USER $USER
19+
20+
# Install fixuid and configure it
21+
RUN curl -SsL https://github.com/boxboat/fixuid/releases/download/v0.6.0/fixuid-0.6.0-linux-amd64.tar.gz | tar -C /usr/local/bin -xzf - && \
22+
chown root:root /usr/local/bin/fixuid && \
23+
chmod 4755 /usr/local/bin/fixuid && \
24+
mkdir -p /etc/fixuid && \
25+
printf "user: $USER\ngroup: $USER\n" > /etc/fixuid/config.yml
2326

2427
# Adds USER to dialout and plugdev group.
2528
# This is needed to access the serial ports, for further references check
2629
# the libserial documentation.
2730
RUN sudo usermod -a -G dialout $USER
2831
RUN sudo usermod -a -G plugdev $USER
2932

33+
USER $USER
34+
3035
# Creates the src folder of the workspace.
3136
RUN mkdir -p /home/$USER/ws/src
3237

33-
# Adds to bashrc the ros humble overlay sourcing.
34-
RUN echo "source /opt/ros/humble/setup.bash" >> /home/$USER/.bashrc
35-
# Adds colcon autocomplete
36-
RUN echo "source /usr/share/colcon_argcomplete/hook/colcon-argcomplete.bash" >> /home/$USER/.bashrc
37-
# Adds gazebo sourcing.
38-
RUN echo "source /usr/share/gazebo/setup.bash" >> /home/$USER/.bashrc
38+
# Adds to bashrc the ros jazzy overlay sourcing.
39+
RUN echo "source /opt/ros/jazzy/setup.bash" >> /home/$USER/.bashrc
3940

4041
# Updates
41-
RUN sudo apt upgrade -y && sudo apt update && rosdep update
42+
RUN sudo apt update && sudo apt upgrade -y && rosdep update
4243

4344
# Defines a workspace folder.
4445
WORKDIR /home/$USER/ws
4546

47+
# Use fixuid as the entrypoint in quiet mode
48+
ENTRYPOINT ["fixuid", "-q"]
49+
4650
CMD ["/bin/bash"]

docker/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ For NVIDIA GPU support, `nvidia-container-toolkit` should be installed. *Skip th
1717

1818
#### Building image and running container
1919

20-
- Build the docker image whose default name is `ros2_humble_andino`:
20+
- Build the docker image whose default name is `ros2_jazzy_andino`:
2121

2222
```sh
2323
./docker/build.sh
@@ -29,7 +29,7 @@ You can also try to set a specific image name:
2929
./docker/build.sh -i my_fancy_image_name
3030
```
3131

32-
- Run a docker container from `ros2_humble_andino` called `ros2_humble_andino_container`:
32+
- Run a docker container from `ros2_jazzy_andino` called `ros2_jazzy_andino_container`:
3333

3434
```sh
3535
./docker/run.sh
@@ -50,7 +50,7 @@ You can also try to set specific image and container names:
5050
- Inside the container, install dependencies via `rosdep`:
5151

5252
```sh
53-
rosdep install -i -y --rosdistro humble --from-paths src
53+
rosdep install -i -y --rosdistro jazzy --from-paths src
5454
```
5555

5656
Note that the repository is mounted into a workspace. That is convenient if you

docker/build.sh

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -36,12 +36,12 @@ set -e
3636
function show_help() {
3737
echo $'\nUsage:\t build.sh [OPTIONS] \n
3838
Options:\n
39-
\t-i --image_name\t\t Name of the image to be built (default ros2_humble_andino).\n
39+
\t-i --image_name\t\t Name of the image to be built (default ros2_jazzy_andino).\n
4040
Example:\n
4141
\tbuild.sh --image_name custom_image_name\n'
4242
}
4343

44-
echo "Building the docker image for ros2 humble andino development."
44+
echo "Building the docker image for ros2 jazzy andino development."
4545

4646
SCRIPT_FOLDER_PATH="$(cd "$(dirname "$0")"; pwd)"
4747
CONTEXT_FOLDER_PATH="$(cd "$(dirname "$0")"; cd .. ; pwd)"
@@ -57,15 +57,13 @@ while [[ "$#" -gt 0 ]]; do
5757
done
5858

5959
# Update the arguments to default values if needed.
60-
OS_VERSION="focal"
61-
IMAGE_NAME=${IMAGE_NAME:-ros2_humble_andino}
60+
OS_VERSION="noble"
61+
IMAGE_NAME=${IMAGE_NAME:-ros2_jazzy_andino}
6262
DOCKERFILE_PATH=$SCRIPT_FOLDER_PATH/Dockerfile
6363

64-
USERID=$(id -u)
65-
USER=$(whoami)
64+
USER=ubuntu
6665

6766
sudo docker build -t $IMAGE_NAME \
6867
--file $DOCKERFILE_PATH \
69-
--build-arg USERID=$USERID \
7068
--build-arg USER=$USER \
7169
$CONTEXT_FOLDER_PATH

docker/requirements.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,4 +22,5 @@ python3-setuptools
2222
software-properties-common
2323
sudo
2424
tmux
25+
wget
2526
xterm

docker/run.sh

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,8 @@ set +e
3636
function show_help() {
3737
echo $'\nUsage:\t run.sh [OPTIONS] \n
3838
Options:\n
39-
\t-i --image_name\t\t Name of the image to be run (default ros2_humble_andino).\n
40-
\t-c --container_name\t Name of the container(default ros2_humble_andino_container).\n
39+
\t-i --image_name\t\t Name of the image to be run (default ros2_jazzy_andino).\n
40+
\t-c --container_name\t Name of the container(default ros2_jazzy_andino_container).\n
4141
\t--use_nvidia\t\t Use nvidia runtime.\n
4242
Examples:\n
4343
\trun.sh\n
@@ -79,22 +79,20 @@ done
7979

8080
# Update the arguments to default values if needed.
8181

82-
IMAGE_NAME=${IMAGE_NAME:-ros2_humble_andino}
83-
CONTAINER_NAME=${CONTAINER_NAME:-ros2_humble_andino_container}
82+
IMAGE_NAME=${IMAGE_NAME:-ros2_jazzy_andino}
83+
CONTAINER_NAME=${CONTAINER_NAME:-ros2_jazzy_andino_container}
84+
85+
USER=ubuntu
8486

8587
SSH_PATH=/home/$USER/.ssh
86-
WORKSPACE_SRC_CONTAINER=/home/$(whoami)/ws/src/$REPOSITORY_FOLDER_NAME
87-
WORKSPACE_ROOT_CONTAINER=/home/$(whoami)/ws
88+
WORKSPACE_SRC_CONTAINER=/home/$USER/ws/src/$REPOSITORY_FOLDER_NAME
89+
WORKSPACE_ROOT_CONTAINER=/home/$USER/ws
8890
SSH_AUTH_SOCK_USER=$SSH_AUTH_SOCK
8991

9092
# Create cache folders to store colcon build files
9193
mkdir -p ${REPOSITORY_FOLDER_PATH}/.build
9294
mkdir -p ${REPOSITORY_FOLDER_PATH}/.install
9395

94-
# Transfer the ownership to the user
95-
chown -R "$USER" ${REPOSITORY_FOLDER_PATH}/.build
96-
chown -R "$USER" ${REPOSITORY_FOLDER_PATH}/.install
97-
9896
# Check if name container is already taken.
9997
if sudo -g docker docker container ls -a | grep "${CONTAINER_NAME}$" -c &> /dev/null; then
10098
printf "Error: Docker container called $CONTAINER_NAME is already opened. \
@@ -113,6 +111,7 @@ sudo docker run --privileged --net=host -it $NVIDIA_FLAGS \
113111
-v ${REPOSITORY_FOLDER_PATH}/.build:$WORKSPACE_ROOT_CONTAINER/build:rw \
114112
-v ${REPOSITORY_FOLDER_PATH}/.install:$WORKSPACE_ROOT_CONTAINER/install:rw \
115113
-v $SSH_PATH:$SSH_PATH \
114+
-u 1000:1000 \
116115
--name $CONTAINER_NAME $IMAGE_NAME
117116
xhost -
118117

0 commit comments

Comments
 (0)