1+ # NOTE: this workflow is now running on Dronecode / PX4 AWS account.
2+ # - If you want to keep the tests running in GitHub Actions you need to uncomment the "runs-on: ubuntu-latest" lines
3+ # and comment the "runs-on: [runs-on,runner=..." lines.
4+ # - If you would like to duplicate this setup try setting up "RunsOn" on your own AWS account try https://runs-on.com
5+
16name : ROS Integration Tests
27
38on :
49 push :
510 branches :
611 - ' main'
12+ paths-ignore :
13+ - ' docs/**'
14+ - ' .github/**'
715 pull_request :
816 branches :
917 - ' *'
18+ paths-ignore :
19+ - ' docs/**'
20+ - ' .github/**'
1021
1122jobs :
1223 build :
13- runs-on : ubuntu-latest
24+ runs-on : [runs-on,runner=16cpu-linux-x64,image=ubuntu22-full-x64,"run-id=${{ github.run_id }}",spot=false]
1425 container :
1526 image : px4io/px4-dev-ros2-galactic:2021-09-08
1627 options : --privileged --ulimit core=-1 --security-opt seccomp=unconfined
1728 steps :
18- - uses : actions/checkout@v1
29+ - uses : actions/checkout@v4
1930 with :
20- token : ${{ secrets.ACCESS_TOKEN }}
31+ fetch-depth : 0
32+
33+ - name : Git Ownership Workaround
34+ run : git config --system --add safe.directory '*'
2135
2236 - name : Install gazebo
2337 run : |
3044 string(TIMESTAMP current_date "%Y-%m-%d-%H;%M;%S" UTC)
3145 message("::set-output name=timestamp::${current_date}")
3246 - name : ccache cache files
33- uses : actions/cache@v2
47+ uses : actions/cache@v4
3448 with :
3549 path : ~/.ccache
3650 key : ros_integration_tests-${{matrix.config.build_type}}-ccache-${{steps.ccache_cache_timestamp.outputs.timestamp}}
5266 git clone --recursive https://github.com/eProsima/Micro-XRCE-DDS-Agent.git
5367 cd Micro-XRCE-DDS-Agent
5468 git checkout v2.2.1 # recent versions require cmake 3.22, but px4-dev-ros2-galactic:2021-09-08 is on 3.16
69+ sed -i 's/_fastdds_tag 2.8.x/_fastdds_tag 2.8.2/g' CMakeLists.txt
5570 mkdir build
5671 cd build
5772 cmake ..
@@ -62,12 +77,15 @@ jobs:
6277 - name : Get and build the ros2 interface library
6378 shell : bash
6479 run : |
80+ PX4_DIR="$(pwd)"
6581 . /opt/ros/galactic/setup.bash
6682 mkdir -p /opt/px4_ws/src
6783 cd /opt/px4_ws/src
6884 git clone --recursive https://github.com/Auterion/px4-ros2-interface-lib.git
6985 cd ..
70- vcs import --input src/px4-ros2-interface-lib/dependencies.repos src
86+ # Copy messages to ROS workspace
87+ "${PX4_DIR}/Tools/copy_to_ros_ws.sh" "$(pwd)"
88+ rm -rf src/translation_node src/px4_msgs_old
7189 colcon build --symlink-install
7290 - name : ccache post-run ros workspace
7391 run : ccache -s
@@ -94,3 +112,12 @@ jobs:
94112 test/ros_test_runner.py --verbose --model iris --upload --force-color
95113 timeout-minutes : 45
96114
115+ - name : Upload failed logs
116+ if : failure()
117+ uses : actions/upload-artifact@v4
118+ with :
119+ name : failed-logs.zip
120+ path : |
121+ logs/**/**/**/*.log
122+ logs/**/**/**/*.ulg
123+ build/px4_sitl_default/tmp_ros_tests/rootfs/log/**/*.ulg
0 commit comments