Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ci: add sonarqube-sync workflow #481

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -16,7 +16,7 @@ env:
jobs:
test:
name: Lint & Test
runs-on: ubuntu-20.04
runs-on: ubuntu-24.04
if: (!contains(github.ref, 'refs/heads/master') || contains(github.ref, 'refs/tags/v'))
timeout-minutes: 10
steps:
@@ -40,7 +40,7 @@ jobs:
- name: Test
run: pnpm test:ember
build:
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
needs: test
if: contains(github.ref, 'refs/tags/v')
timeout-minutes: 10
@@ -75,7 +75,7 @@ jobs:
cname: storybook.upfluence.co
release:
name: Release Package
runs-on: ubuntu-20.04
runs-on: ubuntu-24.04
needs: test
if: contains(github.ref, 'refs/tags/v')
timeout-minutes: 10
41 changes: 41 additions & 0 deletions .github/workflows/sonarqube-sync.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
name: ci

on:
push:
branches:
- master
env:
NODE_VERSION: '20'
GITHUB_TOKEN: ${{ secrets.PAT_TOKEN }}
FONTAWESOME_NPM_AUTH_TOKEN: ${{ secrets.FONTAWESOME_NPM_AUTH_TOKEN }}

jobs:
sonar-report:
name: Sync Sonar Report
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v3
- uses: webfactory/ssh-agent@v0.5.0
with:
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }}
- uses: pnpm/action-setup@v4
with:
version: 10
- uses: actions/setup-node@v4
with:
node-version: '${{ env.NODE_VERSION }}'
cache: 'pnpm'
- name: Install Dependencies
run: pnpm install
env:
GITHUB_TOKEN: ${{ secrets.PAT_TOKEN }}
- name: Run tests
run: pnpm test:coverage
- name: SonarQube Scan
uses: sonarsource/sonarqube-scan-action@v2.0.2
with:
args: >
-Dsonar.projectKey=${{ github.event.repository.name }}
env:
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
SONAR_HOST_URL: ${{ secrets.SONAR_HOST_URL }}
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
@@ -27,6 +27,7 @@
"test": "npm-run-all lint:* test:*",
"test:ember": "ember test --silent -r dot",
"test:ember-compatibility": "ember try:each",
"test:coverage": "COVERAGE=true pnpm test:ember",
"storybook": "cp -R public/assets/fonts app/styles/core && start-storybook -p 6006 -s dist",
"build-storybook": "build-storybook -s dist",
"prepack": "ember ts:precompile",
Loading