ci: run serverless offine in workflow #122
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Serverless Boilerplate | |
on: [push] | |
jobs: | |
tests: | |
runs-on: ubuntu-latest | |
name: Build | |
strategy: | |
matrix: | |
node-version: [20] | |
steps: | |
- uses: actions/checkout@v4 | |
- run: cp .env.dist .env | |
- run: npm ci | |
- run: npm run docker-build | |
- run: docker-compose up -d | |
- run: npm run lint | |
- run: npm run dev | |
- run: npm run test-coverage | |
sonarqube-analysis: | |
runs-on: ubuntu-latest | |
needs: tests | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: SonarQube Scan | |
uses: sonarsource/sonarqube-scan-action@master | |
env: | |
SONAR_TOKEN: sqp_cdf796a422338de063410c70229532ccd1326375 | |
SONAR_HOST_URL: https://sonarqube.aws.tshdev.io |