chore: Update Debricked CLI download URL and vulnerability scan confi… #35
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: Node.js CI 🚀 | |
# This workflow will do a clean install of node dependencies, build the project, and run tests across different versions of node | |
on: | |
push: | |
branches: [main] | |
pull_request: | |
branches: [main] | |
jobs: | |
build: # 🏗️ Build Job | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
node-version: [20.x, 21.x] | |
steps: | |
- name: 📥 Checkout code | |
uses: actions/checkout@v3 | |
- name: 📌 Setup Node.js ${{ matrix.node-version }} | |
uses: actions/setup-node@v3 | |
with: | |
node-version: ${{ matrix.node-version }} | |
- name: 📦 Install dependencies | |
run: npm ci | |
- name: 🏗️ Build the project | |
run: npm run build --if-present | |
- name: 🧪 Run tests with coverage | |
run: npm run test:coverage | |
env: | |
CI: true | |
- name: 🎭 Mask Debricked credentials | |
run: | | |
echo "::add-mask::${{ secrets.DEBRICKED_USERNAME }}" | |
echo "::add-mask::${{ secrets.DEBRICKED_PASSWORD }}" | |
- name: Install Debricked CLI | |
run: | | |
curl -L https://github.com/debricked/cli/releases/latest/download/cli_linux_x86_64.tar.gz | tar -xz debricked | |
tar -xzf debricked.tar.gz | |
sudo mv debricked /usr/local/bin/debricked | |
- name: 🛡️ Debricked Vulnerability Scan | |
run: | | |
debricked ci:upload -u ${{ secrets.DEBRICKED_USERNAME }} -p ${{ secrets.DEBRICKED_PASSWORD }} -r ${{ github.repository }} -c ${{ github.sha }} |