1
0
Fork 0
mirror of https://github.com/kyverno/kyverno.git synced 2024-12-14 11:57:48 +00:00
kyverno/.github/workflows/sonarcloud.yaml

36 lines
970 B
YAML
Raw Normal View History

name: Sonarcloud workflow
permissions: {}
on:
push:
branches:
- 'main'
- 'release*'
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
sonarcloud:
runs-on: ubuntu-latest
steps:
chore: add setup-build-env gh action (#5892) * chore: use gh composite actions Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * failure Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * failure Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * failure Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * failure Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * wait ready Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * restart Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * chore: add setup-build-env gh action Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * fix clone Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * fix Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * unshallow Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * unshallow Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * unshallow Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * unshallow Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * unshallow Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * unshallow Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * unshallow Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * unshallow Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * unshallow Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * unshallow Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * cache Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * cache Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * cache Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * cache Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * cache Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * cache Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * cache Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * cache Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> Signed-off-by: Charles-Edouard Brétéché <charled.breteche@gmail.com>
2023-01-05 15:52:52 +00:00
- name: Checkout
uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4.1.0
- name: Check secret
id: checksecret
uses: ./.github/actions/is-defined
with:
value: ${{ secrets.SONAR_TOKEN }}
chore: add setup-build-env gh action (#5892) * chore: use gh composite actions Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * failure Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * failure Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * failure Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * failure Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * wait ready Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * restart Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * chore: add setup-build-env gh action Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * fix clone Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * fix Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * unshallow Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * unshallow Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * unshallow Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * unshallow Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * unshallow Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * unshallow Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * unshallow Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * unshallow Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * unshallow Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * unshallow Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * cache Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * cache Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * cache Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * cache Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * cache Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * cache Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * cache Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * cache Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> Signed-off-by: Charles-Edouard Brétéché <charled.breteche@gmail.com>
2023-01-05 15:52:52 +00:00
- name: Setup build env
if: steps.checksecret.outputs.result == 'true'
chore: add setup-build-env gh action (#5892) * chore: use gh composite actions Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * failure Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * failure Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * failure Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * failure Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * wait ready Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * restart Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * chore: add setup-build-env gh action Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * fix clone Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * fix Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * unshallow Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * unshallow Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * unshallow Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * unshallow Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * unshallow Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * unshallow Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * unshallow Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * unshallow Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * unshallow Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * unshallow Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * cache Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * cache Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * cache Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * cache Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * cache Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * cache Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * cache Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> * cache Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> Signed-off-by: Charles-Edouard Brétéché <charles.edouard@nirmata.com> Signed-off-by: Charles-Edouard Brétéché <charled.breteche@gmail.com>
2023-01-05 15:52:52 +00:00
uses: ./.github/actions/setup-build-env
timeout-minutes: 10
- name: SonarCloud Scan
if: steps.checksecret.outputs.result == 'true'
uses: sonarsource/sonarcloud-github-action@db501078e936e4b4c8773d1bb949ba9ddb7b6b6a # v1.9
env:
GITHUB_TOKEN: ${{ secrets.ACCESS_TOKEN }}
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}