-
Notifications
You must be signed in to change notification settings - Fork 389
49 lines (48 loc) · 1.67 KB
/
next-scan.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
on:
# Trigger analysis when pushing in master or pull requests, and when creating
# a pull request.
push:
branches:
- master
pull_request:
types: [opened, synchronize, reopened]
name: Main Workflow
jobs:
next:
runs-on: ubuntu-latest
permissions:
id-token: write
pull-requests: read
contents: read
steps:
- uses: actions/checkout@v3
with:
# Disabling shallow clone is recommended for improving relevancy of reporting
fetch-depth: 0
- uses: azure/setup-helm@v3
with:
version: latest # default is latest (stable)
token: ${{ secrets.GITHUB_TOKEN }} # only needed if version is 'latest'
id: install-helm
- id: secrets
uses: SonarSource/[email protected]
with:
secrets: |
development/kv/data/next token | sq_next_token;
- name: run templating
run: |
helm repo add ingress-nginx https://kubernetes.github.io/ingress-nginx
helm repo add bitnami https://charts.bitnami.com/bitnami
helm repo add bitnami-pre2022 https://raw.githubusercontent.com/bitnami/charts/pre-2022/bitnami
cd ${{ github.workspace }}/charts/sonarqube
helm dependency build
../../.cirrus/generate-yaml-for-next-scan.sh
cd ${{ github.workspace }}/charts/sonarqube-dce
helm dependency build
../../.cirrus/generate-yaml-for-next-scan.sh
- name: SonarQube Next Scan
uses: sonarsource/sonarqube-scan-action@master
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
SONAR_TOKEN: ${{ fromJSON(steps.secrets.outputs.vault).sq_next_token }}
SONAR_HOST_URL: https://next.sonarqube.com