31 lines
1.0 KiB
YAML
31 lines
1.0 KiB
YAML
name: "K8S Fission Code Analystics"
|
|
on:
|
|
workflow_dispatch:
|
|
jobs:
|
|
sonarqube:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
with:
|
|
fetch-depth: 0
|
|
- name: 🔍 SonarQube Scan
|
|
id: scan
|
|
uses: sonarsource/sonarqube-scan-action@master
|
|
env:
|
|
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
|
|
SONAR_HOST_URL: ${{ secrets.SONAR_HOST_URL }}
|
|
with:
|
|
args: >
|
|
-Dsonar.projectKey=${{ github.event.repository.name }} -Dsonar.sources=.
|
|
- name: 🔔 Send notification
|
|
uses: appleboy/telegram-action@master
|
|
if: always()
|
|
with:
|
|
to: ${{ secrets.TELEGRAM_TO }}
|
|
token: ${{ secrets.TELEGRAM_TOKEN }}
|
|
format: markdown
|
|
socks5: ${{ secrets.TELEGRAM_PROXY_URL != '' && secrets.TELEGRAM_PROXY_URL || '' }}
|
|
message: |
|
|
${{ steps.scan.outcome == 'success' && '🟢 (=^ ◡ ^=)' || '🔴 (。•́︿•̀。)' }} Scanned ${{ github.event.repository.name }}
|
|
*Msg*: `${{ github.event.commits[0].message }}`
|