ros1-talker-listener
ROS 1 talker/listener demo over Husarnet vpn
Prerequisites
Make sure you have Docker and Docker Compose v2 installed on your laptop. Tested on Ubuntu 20.04.
If you don't have, here's a quick summary for Ubuntu 20.04:
Installing Docker (just click the
copy
button, and paste it to the Linux terminal):sudo apt-get update && sudo apt-get install -y ca-certificates curl gnupg lsb-release
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo gpg --dearmor -o /usr/share/keyrings/docker-archive-keyring.gpg
echo \ "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] https://download.docker.com/linux/ubuntu \ $(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/nullsudo apt-get update && sudo apt-get install docker-ce docker-ce-cli containerd.io
Installing Docker Compose v2
mkdir -p /usr/local/lib/docker/cli-pluginscurl -SL https://github.com/docker/compose/releases/download/v2.2.3/docker-compose-linux-x86_64 -o /usr/local/lib/docker/cli-plugins/docker-composechmod +x /usr/local/lib/docker/cli-plugins/docker-compose
Basic Talker/Listener ROS 1 demo on a single host in Docker
docker compose up
ROS 1 Talker/Listener demo over the Internet
At first find your Husarnet JoinCode on your account at https://app.husarnet.com and paste it in the .env
file, eg.:
HUSARNET_JOINCODE=fc94:b01d:1803:8dd8:b293:5c7d:7639:932a/K5bDunnExmaKDpZJbiMMuV
Then run:
docker compose -f compose.talker.yaml up
on the first machine, and ...
docker compose -f compose.listener.yaml up
on the second one