Skip to content

Merge branch 'stackable' of https://github.com/stackabletech/SecObser… #411

Merge branch 'stackable' of https://github.com/stackabletech/SecObser…

Merge branch 'stackable' of https://github.com/stackabletech/SecObser… #411

name: Check frontend
on: [push, pull_request]
permissions: {}
jobs:
code_quality:
permissions:
contents: read
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: false
- uses: actions/setup-node@53b83947a5a98c8d113130e565377fae1a50d02f # v6.3.0
with:
node-version: 24
- name: Install dependencies
working-directory: ./frontend
run: |
npm ci
- name: Prettier
working-directory: ./frontend
run: |
npx prettier -c src
- name: ESLint
working-directory: ./frontend
run: |
npx eslint src
end_to_end_tests:
permissions:
contents: read
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: false
- name: End-to-end tests
working-directory: .
run: |
cd end_to_end_tests
npm install
cd ..
docker compose -f docker-compose-playwright.yml build
docker compose -f docker-compose-playwright.yml up --abort-on-container-exit --exit-code-from playwright
check_code_sonarqube_frontend:
permissions:
contents: read
if: github.repository == 'SecObserve/SecObserve' && (github.ref == 'refs/heads/dev' || github.event_name == 'pull_request')
runs-on: ubuntu-latest
steps:
-
name: Checkout code
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: false
fetch-depth: 0
-
name: Run SonarQube scan for frontend
uses: SonarSource/sonarqube-scan-action@a31c9398be7ace6bbfaf30c0bd5d415f843d45e9 # v7.0.0
env:
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN_FRONTEND }}
with:
projectBaseDir: frontend