Fix: Adjust directory tree ownership on gtest-bare-metal.yml (#1181) #1952
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Centos build | |
on: | |
# allow manually trigger | |
workflow_dispatch: | |
push: | |
branches: | |
- main | |
- 'maint-**' | |
pull_request: | |
branches: | |
- main | |
- 'maint-**' | |
permissions: | |
contents: read | |
env: | |
DPDK_VERSION: 25.03 | |
jobs: | |
changes: | |
runs-on: ubuntu-latest | |
permissions: | |
pull-requests: read | |
outputs: | |
changed: ${{ steps.filter.outputs.centos_build == 'true' }} | |
steps: | |
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | |
- uses: dorny/paths-filter@de90cc6fb38fc0963ad72b210f1f284cd68cea36 # v2 | |
id: filter | |
with: | |
filters: .github/path_filters.yml | |
build: | |
needs: changes | |
if: ${{ github.repository == 'OpenVisualCloud/Media-Transport-Library' && needs.changes.outputs.changed == 'true' }} | |
runs-on: ${{ matrix.os }} | |
timeout-minutes: 60 | |
container: | |
image: quay.io/centos/centos:stream8 | |
strategy: | |
matrix: | |
os: [ubuntu-latest] | |
steps: | |
- name: Harden Runner | |
uses: step-security/harden-runner@4d991eb9b905ef189e4c376166672c3f2f230481 # v2.11.0 | |
with: | |
egress-policy: audit | |
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 | |
- uses: DoozyX/clang-format-lint-action@v0.20 | |
with: | |
clangFormatVersion: '14' | |
source: '.' | |
extensions: 'hpp,h,cpp,c,cc' | |
- name: Install the build dependency | |
run: | | |
sed -i 's/mirrorlist/#mirrorlist/g' /etc/yum.repos.d/CentOS-* | |
sed -i 's|#baseurl=http://mirror.centos.org|baseurl=http://vault.centos.org|g' /etc/yum.repos.d/CentOS-* | |
yum install -y dnf-plugins-core | |
dnf config-manager --set-enabled powertools | |
yum install -y epel-release | |
yum install -y sudo git gcc gcc-c++ meson python3 python3-pyelftools pkg-config json-c-devel libpcap-devel gtest-devel SDL2-devel openssl-devel numactl-devel libasan | |
yum install -y systemtap-sdt-devel clang llvm-devel | |
- name: Install DPDK | |
uses: ./.github/actions/dpdk | |
with: | |
version: ${{ env.DPDK_VERSION }} | |
- name: Git config | |
run: | | |
git config --global user.email "you@example.com" | |
git config --global user.name "Your Name" | |
- name: Build | |
run: | | |
export PKG_CONFIG_PATH=/usr/local/lib64/pkgconfig/:/usr/local/lib/pkgconfig/ | |
./build.sh | |
- name: Build with debug | |
run: | | |
rm build -rf | |
export PKG_CONFIG_PATH=/usr/local/lib64/pkgconfig/:/usr/local/lib/pkgconfig/ | |
./build.sh debug |