Skip to content

[DLSPS] Coverity scan (by @hteeyeoh via push) #2

[DLSPS] Coverity scan (by @hteeyeoh via push)

[DLSPS] Coverity scan (by @hteeyeoh via push) #2

name: "[DLSPS] Coverity workflow for C/C++"
run-name: "[DLSPS] Coverity scan (by @${{ github.actor }} via ${{ github.event_name }})"
on:
push:
branches:
- 'main'
paths:
- 'microservices/dlstreamer-pipeline-server/**'
pull_request:
paths:
- 'microservices/dlstreamer-pipeline-server/**'
workflow_call:
permissions: {}
jobs:
coverity-scan:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
strategy:
fail-fast: false
matrix:
include:
- ubuntu_version: ubuntu22
steps:
- name: Check out edge-ai-libraries repository
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 #4.2.2
with:
persist-credentials: false
path: edge-ai-libraries-repo
- name: Log in to GitHub Container Registry
uses: docker/login-action@74a5d142397b4f367a81961eba4e8cd7edddf772 #3.4.0
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build dls-pipeline-server-img
run: |
cd edge-ai-libraries-repo/microservices/dlstreamer-pipeline-server/docker
export DLSTREAMER_PIPELINE_SERVER_IMAGE=intel/dlstreamer-pipeline-server:coverity-${{ matrix.ubuntu_version }}
export DLSTREAMER_PIPELINE_SERVER_DOCKERFILE=Dockerfile
export BASE_IMAGE="ghcr.io/open-edge-platform/edge-ai-libraries/deb-final-img-ubuntu22:candidate1407"
export BUILD_TARGET=gstudfloader-builder
docker compose build --no-cache --pull
- name: Run Coverity Scans.
run: |
cd edge-ai-libraries-repo/microservices/dlstreamer-pipeline-server/tests
echo DLSPS_COVERITY_TOKEN=${{secrets.DLSPS_COVERITY_TOKEN}} >> .env
echo DLSPS_COVERITY_EMAIL=${{secrets.DLSPS_COVERITY_EMAIL}} >> .env
echo DLSPS_COVERITY_PROJECT=${{secrets.DLSPS_COVERITY_PROJECT}} >> .env
docker run --rm --env-file .env -v `pwd`:/app -v /tmp:/tmp intel/dlstreamer-pipeline-server:coverity-ubuntu22 /bin/bash /app/coverity.sh
- name: Upload Coverity Reports to Github
uses: actions/upload-artifact@v4
with:
name: Coverity-reports
path: /tmp/coverity-output.tgz
- name: Clean up
if: always()
run: |
rm -rf edge-ai-libraries-repo
sudo rm -rf /tmp/coverity-output.tgz
docker rmi intel/dlstreamer-pipeline-server:coverity-${{ matrix.ubuntu_version }} || true