From 6a966cd5f6054020bf07762caffb792668a97e97 Mon Sep 17 00:00:00 2001 From: Andrey Kashchikhin Date: Fri, 27 Oct 2023 10:25:01 +0100 Subject: [PATCH] [CI] [GHA] Add system information print action (#20710) * added action * test action * fixed typo * move action to test flow * fixed pipeline * changed description * add action to common pipeline * changed actions path * use bash syntax * path * fix * reordered * update * revert unused changes * update path * Revert "update path" This reverts commit bff8ac23969dc6ce83631ec4d6997ecdff677b31. * mac and win * print system info * correct pathg * use relative path * run mac * add print sysinfo step, enable triggers * use win agnostic func * rm triggers * mv sysinfo check after checkouts; rm tools versions info printing * correct desc * add sysinfo dep for fedora * mv pre-requisite installation --------- Co-authored-by: Mikhail Ryzhov --- .github/actions/system_info/action.yml | 34 +++++++++++++++++++ .github/workflows/android_arm64.yml | 7 ++++ .github/workflows/fedora.yml | 7 ++++ .github/workflows/linux.yml | 7 ++++ .../linux_conditional_compilation.yml | 7 ++++ .github/workflows/linux_riscv.yml | 7 ++++ .github/workflows/mac.yml | 7 ++++ .github/workflows/windows.yml | 7 ++++ .../windows_conditional_compilation.yml | 7 ++++ 9 files changed, 90 insertions(+) create mode 100644 .github/actions/system_info/action.yml diff --git a/.github/actions/system_info/action.yml b/.github/actions/system_info/action.yml new file mode 100644 index 00000000000000..fb4ff1a9520c95 --- /dev/null +++ b/.github/actions/system_info/action.yml @@ -0,0 +1,34 @@ +name: 'System Information' +description: 'Information about the system' +runs: + using: "composite" + steps: + - if: runner.os == 'Linux' + shell: bash + run: | + # Install pre-requisites for Fedora + if [[ -e /etc/fedora-release ]]; then + yum update -y -q && yum install -y -q procps + fi + + echo "System: ${{ runner.os }}" + echo "System Architecture: ${{ runner.arch }}" + echo "CPU Info: "; lscpu + echo "RAM Info: "; free -h --si + echo "MEMORY Info: "; df -h + + - if: runner.os == 'macOS' + shell: bash + run: | + echo "System: ${{ runner.os }}" + echo "System Architecture: ${{ runner.arch }}" + echo "CPU and RAM Info: "; system_profiler SPHardwareDataType + echo "MEMORY Info: "; df -h + + - if: runner.os == 'Windows' + shell: pwsh + run: | + echo "System: ${{ runner.os }}" + echo "System Architecture: ${{ runner.arch }}" + echo "CPU Info: "; Get-CimInstance –ClassName Win32_Processor | Select-Object -Property Name, NumberOfCores, NumberOfLogicalProcessors + echo "RAM info: $(systeminfo | Select-String 'Total Physical Memory:')" diff --git a/.github/workflows/android_arm64.yml b/.github/workflows/android_arm64.yml index 34487b04903d70..deacec70e344ea 100644 --- a/.github/workflows/android_arm64.yml +++ b/.github/workflows/android_arm64.yml @@ -77,6 +77,13 @@ jobs: path: 'vcpkg' fetch-depth: '0' + # + # Print system info + # + + - name: System info + uses: ./openvino/.github/actions/system_info + # # Dependencies # diff --git a/.github/workflows/fedora.yml b/.github/workflows/fedora.yml index 3bb6b69c76d1f1..b7ae5765971206 100644 --- a/.github/workflows/fedora.yml +++ b/.github/workflows/fedora.yml @@ -59,6 +59,13 @@ jobs: path: ${{ env.OPENVINO_REPO }} submodules: 'true' + # + # Print system info + # + + - name: System info + uses: ./openvino/.github/actions/system_info + # # Dependencies # diff --git a/.github/workflows/linux.yml b/.github/workflows/linux.yml index ae512a64393a19..888358d10b1182 100644 --- a/.github/workflows/linux.yml +++ b/.github/workflows/linux.yml @@ -81,6 +81,13 @@ jobs: submodules: 'true' ref: 'master' + # + # Print system info + # + + - name: System info + uses: ./openvino/.github/actions/system_info + # # Dependencies # diff --git a/.github/workflows/linux_conditional_compilation.yml b/.github/workflows/linux_conditional_compilation.yml index 74bfd4e2e203ce..7fac5d9a1bde98 100644 --- a/.github/workflows/linux_conditional_compilation.yml +++ b/.github/workflows/linux_conditional_compilation.yml @@ -75,6 +75,13 @@ jobs: lfs: 'true' ref: 'master' + # + # Print system info + # + + - name: System info + uses: ./openvino/.github/actions/system_info + # # Dependencies # diff --git a/.github/workflows/linux_riscv.yml b/.github/workflows/linux_riscv.yml index 0b181c3c8ff0ed..25528d96e151db 100644 --- a/.github/workflows/linux_riscv.yml +++ b/.github/workflows/linux_riscv.yml @@ -61,6 +61,13 @@ jobs: with: path: 'openvino' + # + # Print system info + # + + - name: System info + uses: ./openvino/.github/actions/system_info + - name: Init submodules for non-Conan dependencies run: | pushd ${OPENVINO_REPO} diff --git a/.github/workflows/mac.yml b/.github/workflows/mac.yml index c39df9691fd78b..86bee3e82e8df5 100644 --- a/.github/workflows/mac.yml +++ b/.github/workflows/mac.yml @@ -74,6 +74,13 @@ jobs: repository: 'openvinotoolkit/openvino_contrib' path: 'openvino_contrib' + # + # Print system info + # + + - name: System info + uses: ./openvino/.github/actions/system_info + # # Dependencies # diff --git a/.github/workflows/windows.yml b/.github/workflows/windows.yml index 84e9209aecb092..4984826bfba7fd 100644 --- a/.github/workflows/windows.yml +++ b/.github/workflows/windows.yml @@ -62,6 +62,13 @@ jobs: path: 'openvino_contrib' ref: 'master' + # + # Print system info + # + + - name: System info + uses: ./openvino/.github/actions/system_info + # # Dependencies # diff --git a/.github/workflows/windows_conditional_compilation.yml b/.github/workflows/windows_conditional_compilation.yml index d506272d0ad510..976daa18272796 100644 --- a/.github/workflows/windows_conditional_compilation.yml +++ b/.github/workflows/windows_conditional_compilation.yml @@ -64,6 +64,13 @@ jobs: lfs: 'true' ref: 'master' + # + # Print system info + # + + - name: System info + uses: ./openvino/.github/actions/system_info + # # Dependencies #