Skip to content

Leverage docker

Leverage docker #5

name: rclnodejs - Linux Build and Test
on:
push:
branches:
- develop
- jazzy
- iron-irwini
- humble-hawksbill
pull_request:
branches:
- develop
- jazzy
- iron-irwini
- humble-hawksbill
workflow_dispatch:
jobs:
identify-ros-distro:
uses: ./.github/workflows/identify-ros-distro.yml
build:
needs: identify-ros-distro
runs-on: ${{ needs.identify-ros-distro.outputs.linuxos }}
container:
image: osrf/ros:${{ needs.identify-ros-distro.outputs.distro }}-desktop
strategy:
fail-fast: false
matrix:
node-version: [18.X, 20.X]
steps:
- name: Setup Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
- name: Setup ROS2
uses: ros-tooling/setup-ros@0.7.6
- name: Install test-msgs on Linux
run: |
sudo apt install ros-${{ needs.identify-ros-distro.outputs.distro }}-test-msgs
- uses: actions/checkout@v3
- name: Build and test rclnodejs
uses: ros-tooling/action-ros-ci@v0.3
run: |
npm i
npm test