Skip to content

Instantly share code, notes, and snippets.

View hoshiya4522's full-sized avatar
🎯
Messing with Linux

Gourob Dev hoshiya4522

🎯
Messing with Linux
View GitHub Profile

Using Distrobox

First install Distrobox: https://github.com/89luca89/distrobox

After installing, create a new container for ROS2. In this case, we'll be installing Ubuntu 22.04 LTS

distrobox create --name ros --image ubuntu:22.04

To enter the container,

@hoshiya4522
hoshiya4522 / install_ros2.sh
Last active October 7, 2025 14:03
Install ROS on Debian based systems (Tested on Pop!_OS 22.04 LTS x86_64 )
#!/bin/bash
echo "Setting up ROS 2 repository..."
sudo apt install software-properties-common -y
sudo add-apt-repository universe -y
sudo apt update && sudo apt install curl -y
echo "Setting up ROS 2 keyrings..."
sudo curl -sSL https://raw.githubusercontent.com/ros/rosdistro/master/ros.key -o /usr/share/keyrings/ros-archive-keyring.gpg
echo "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/ros-archive-keyring.gpg] http://packages.ros.org/ros2/ubuntu jammy main" | sudo tee /etc/apt/sources.list.d/ros2.list > /dev/null