Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support Dev Container and Codespace for ROS1 Gazebo Tutorial #13

Closed
wants to merge 6 commits into from

Conversation

mjyc
Copy link

@mjyc mjyc commented Jun 9, 2023

Public-Facing Changes

"None"

Description

This PR adds a devcontainer config to run ros1/gazebo on a local machine using vscode + docker (video demo) and on the cloud via codespace (video demo). The goal was to make trying out foxglove tutorials as easy as possible, so devcontainer + codespaces seemed like a handy combination[^1]. The main benefit is the low/no-install experience when following foxglove tutorials, even when a developer needs to use (soon-to-eol-reaching) ROS1 code. Please check out the video, it's a rough cut, but demonstrates what can be done with this PR. Curious to hear peoples thoughts!

Notes

  • To try this PR on your local machine, you still need to install docker, VSCode, and Dev containers vscode extension.
  • I added two almost identical devcontainer.json files--one for codespace and another for local development--to make the devcontainer/codespace integration smooth w/ the existing multi-project folder structure of this tutorial repo (see codesapces w/ monorepo and devcontainers w/ multifolder). It looked like it's difficult to define one devcontainer config that works for both and this issue is being discussed actively, so I decided to take a simple approach (of having duplicates) until the community figures out a direction.
  • On Apple M1 machines, you'll need to (1) set export DOCKER_DEFAULT_PLATFORM=linux/amd64 to build intel container images and (2) turn on "Use Rosetta for x86/amd64 emulation on Apple Silicon" option in Docker Desktop's "Features in development" setting to run gazebo--without it, it complains about the incompatible kernel, etc..
  • It's a prototype, I haven't extensively tested usability.

Quick self-intro & background & acknowledgement

Hello, a foxglove fan here. I've been exploring ways to improve DX of ROS(1) developers[^2]--esp., those who does not own ubuntu machines using devcontainer--and recently saw this related work from Ruffin White. I thought the same idea could be applied to improve the experience of following foxglove tutorials, so here I'm. Many thank yous to Ruffin White who figured out how to make self-hosted foxglove studio on codespace work.

[^1] To learn more about using Devcontainer & Codespace with ROS, see https://navigation.ros.org/development_guides/devcontainer_docs/index.html
[^2] E.g., https://github.com/mjyc/ros-sandbox

@CLAassistant
Copy link

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

@mjyc mjyc changed the title Devel Support Dev Container and Codespace for ros1/gazebo tutorial Jun 9, 2023
@mjyc mjyc marked this pull request as ready for review June 9, 2023 21:27
@mjyc mjyc changed the title Support Dev Container and Codespace for ros1/gazebo tutorial Support Dev Container and Codespace for ROS1 Gazebo Tutorial Jun 10, 2023
@defunctzombie
Copy link
Contributor

Sorry we lost sight of this PR and no one responded. Thanks for proposing these changes but this is more than we can take on maintaining right now. The tutorials repo is more a place where we store the code for the blog posts. I do think this kind of codespaces setup is awesome and worth making easier but not something we are actively working on.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants