Refactor docker structure: split into gazebo/coppeliasim, add UR3e simulation compose - #9
Conversation
…mulation compose - Separate docker/ into self-contained gazebo/ and coppeliasim/ subdirectories - Each subdirectory now includes its own sas_ur_control_template/Dockerfile and scripts/ - Remove shared docker/sas_ur_control_template/ and docker/scripts/ at root - Add docker/gazebo/compose_simulation.yml for UR3e-only Gazebo simulation - Add docker/gazebo/ur3e_simulation_example_py_launch.py launch file - Add .env files in docker/gazebo/ and docker/coppeliasim/ - Update all existing compose files to use local build paths - Updated teleop_demo/Dockerfile script path Co-authored-by: openhands <openhands@all-hands.dev>
- Remove duplicate copies from gazebo/, coppeliasim/, robot_demo/, teleop_demo/ - Keep single shared copies at docker/sas_ur_control_template/ and docker/scripts/ - Update all compose files to reference docker/sas_ur_control_template/Dockerfile - Update robot_demo/compose.yml script path to docker/scripts/ - Update teleop_demo/compose.yml fastrtps_profile path to docker/scripts/ - Update teleop_demo/Dockerfile setup_environment.sh path to docker/scripts/ - Update compose_simulation.yml to use shared Dockerfile Co-authored-by: openhands <openhands@all-hands.dev>
Change OverviewThis PR restructures the 1. Docker Directory Restructure:
|
| Service | Purpose |
|---|---|
sas_ur_control_template |
Builds the control template image and runs ur3e_simulation_example_py_launch.py with robot_topic_name:=ur3e_sim |
gazebo |
Launches gz sim ur3e_world.sdf, the UR3e robot driver (6 joints: shoulder_pan → wrist_3), and the pose control server for base and tool0 frames |
Usage:
cd docker/gazebo && sudo docker compose -f compose_simulation.yml up3. Consolidated Shared Files
Identical copies of sas_ur_control_template/Dockerfile and scripts/ were previously duplicated across gazebo/, coppeliasim/, robot_demo/, and teleop_demo/. These are now single shared copies at docker/sas_ur_control_template/ and docker/scripts/.
All 7 compose files and the teleop_demo/Dockerfile were updated to reference the consolidated paths:
| File | Path Update |
|---|---|
| All compose files | dockerfile: docker/sas_ur_control_template/Dockerfile |
robot_demo/compose.yml |
Script path → docker/scripts/prepare_robot_demo.sh |
teleop_demo/compose.yml |
FastRTPS profile → docker/scripts/fastrtps_profile.xml |
teleop_demo/Dockerfile |
Setup script → docker/scripts/setup_environment.sh |
Net diff: -211 lines removed (duplicates), +10 lines (path updates).
4. Validation
- All 7 compose files validated with
docker compose config - R820 world simulation tested headless (xvfb
:99) — all 4 ROS2 nodes launched successfully - UR3e world simulation tested headless — robot driver server and pose control server initialized; SDF mesh resolution errors are expected (UR3e mesh assets are not included in the test image but will be present in the delivered system)
This comment was written by an AI agent (OpenHands) on behalf of the user.
Test Results — Consolidated StructureAll tests executed against the consolidated docker layout (single 1. Compose YAML ValidationAll 7 compose files parsed cleanly with
2. Docker Image Build
3. Headless Gazebo Simulation (xvfb :99)R820 world (
UR3e world (
4. Control Template Launch File
Tested by an AI agent (OpenHands) on behalf of the user. |
Adds docker/compose.yml, docker/Dockerfile, and docker/test_ci.sh to validate the package in CI: - Builds the package with colcon - Verifies sas_ur_control_template is discoverable - Confirms Python and C++ executables are installed and executable - Validates Python syntax of all launch files Designed for GitHub Actions execution.
CI Test Infrastructure AddedThree new files added to the
What the test validates:
Local test result:Note: Added by an AI agent (OpenHands) on behalf of the user. |
Summary
This PR restructures the
docker/directory into self-containedgazebo/andcoppeliasim/subdirectories, and adds a new UR3e-only Gazebo simulation compose file modeled after theur3e_r820reference repository.This PR was created by an AI agent (OpenHands) on behalf of the user.
Changes
New Files
docker/gazebo/compose_simulation.yml— UR3e-only simulation compose with two services:sas_ur_control_template: builds from local Dockerfile, runs the UR3e simulation launchgazebo: launchesgz sim ur3e_world.sdf, UR3e robot driver (6 joints), and pose control serverdocker/gazebo/ur3e_simulation_example_py_launch.py— Launch file for the UR3e simulation control template nodedocker/gazebo/.env— Environment variables for Gazebo simulation (world name, robot name, topic name)docker/coppeliasim/.env— Environment variables for CoppeliaSim simulation (scene file, topic name)Restructured Directories
Each subdirectory is now self-contained with its own
sas_ur_control_template/Dockerfileandscripts/:docker/gazebo/compose.yml,compose_simulation.yml,ur3e_simulation_example_py_launch.py,sas_ur_control_template/,scripts/,.envdocker/coppeliasim/simulation_demo_v2/,simulation_demo_v2_kinematic/,sas_ur_control_template/,scripts/,.envdocker/robot_demo/compose.yml,sas_ur_control_template/,scripts/docker/teleop_demo/Dockerfile,compose.yml,sas_ur_control_template/,scripts/Removed (migrated to subdirectories)
docker/sas_ur_control_template/→ copied intogazebo/,coppeliasim/,robot_demo/,teleop_demo/docker/scripts/→ copied intogazebo/,coppeliasim/,robot_demo/,teleop_demo/Updated Compose Files
simulation_demo_v2/compose.yml— local build pathsimulation_demo_v2_kinematic/compose.yml— local build pathrobot_demo/compose.yml— local build path, updated script pathteleop_demo/compose.yml— local build path, updated fastrtps profile pathteleop_demo/Dockerfile— fixed script path from.devel/scriptstodocker/teleop_demo/scriptsUsage
Validation
All 7 compose files validated successfully with
docker compose config.