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

Docker CI #19

Merged
merged 10 commits into from
Nov 20, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
48 changes: 38 additions & 10 deletions .github/workflows/cpp_ubuntu20_04.yml
Original file line number Diff line number Diff line change
@@ -1,17 +1,45 @@
name: C++ Ubuntu 20.04

name: lpp
on:
push:
branches:
- "master"
pull_request:
branches:
- "master"

jobs:
build:

runs-on: ubuntu-20.04

runs-on: [self-hosted, linux]
strategy:
fail-fast: false
matrix:
rosdistro: ['noetic']
gcc: ['8', '9', '10']
container: ros:${{ matrix.rosdistro }}-ros-base-focal
name: ROS ${{ matrix.rosdistro }} - GCC ${{ matrix.gcc }}
steps:
- uses: actions/checkout@v3
- name: Run build script
run: ./.github/scripts/run_build_ubuntu20_04.sh
name: Checkout lpp
with:
repository: ethz-asl/lpp
token: ${{ secrets.PAT }}
path: catkin_ws/src/lpp

- name: Install newest git version
run: sudo apt update && sudo apt-get install -y software-properties-common && sudo add-apt-repository -y ppa:git-core/ppa && sudo apt-get update && sudo apt-get install -y git

- name: Install GCC version ${{ matrix.gcc }}
run: sudo add-apt-repository ppa:ubuntu-toolchain-r/ppa -y && sudo apt update && sudo apt install -y gcc-${{ matrix.gcc }} g++-${{ matrix.gcc }} && sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-${{ matrix.gcc }} 100 --slave /usr/bin/g++ g++ /usr/bin/g++-${{ matrix.gcc }}

- name: Install catkin tools
run: sudo apt install -y python3-rosdep python3-rosinstall python3-rosinstall-generator python3-wstool build-essential python3-catkin-tools

- name: Install system dependencies
run: sudo apt install -y libgoogle-glog-dev

- name: Build lpp
run: source /opt/ros/${{ matrix.rosdistro }}/setup.bash && catkin build lpp && source ${GITHUB_WORKSPACE}/catkin_ws/devel/setup.bash
working-directory: catkin_ws
shell: bash

- name: Run unittests
run: source /opt/ros/${{ matrix.rosdistro }}/setup.bash && source ${GITHUB_WORKSPACE}/catkin_ws/devel/setup.bash && rosrun lpp test_lpp && rosrun lpp test_glog && rosrun lpp test_lpp_custom && rosrun lpp test_nolog && rosrun lpp test_default && rosrun lpp test_roslog
working-directory: catkin_ws
shell: bash