diff --git a/.circleci/config.yml b/.circleci/config.yml index 8bb4767..e154345 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -5,17 +5,7 @@ orbs: node: circleci/node@5.2.0 jobs: - check-node-version: - executor: node/default - steps: - - checkout - - node/install-packages: - pkg-manager: npm - - run: - command: node -v - name: Check Node.js Version - - check-vulnerabilities: + fix-vulnerabilities: executor: node/default docker: - image: cimg/node:20.11.0-browsers @@ -24,18 +14,23 @@ jobs: - node/install-packages: pkg-manager: npm - run: - command: npm audit fix --force --json + name: Run Vulnerability Scan + command: npm audit --json + - run: name: Fix Vulnerabilities - + command: npm audit fix --force --json + build-app: executor: node/default + docker: + - image: cimg/node:20.11.0-browsers steps: - checkout - node/install-packages: pkg-manager: npm - run: - command: npm install name: Build app + command: npm install # - persist_to_workspace: # root: ~/project # paths: @@ -52,8 +47,7 @@ jobs: workflows: check-fix-build-app: jobs: - - check-node-version - - check-vulnerabilities + - fix-vulnerabilities - build-app # - deploy: # requires: diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml deleted file mode 100644 index faf82d0..0000000 --- a/.github/workflows/main.yml +++ /dev/null @@ -1,23 +0,0 @@ -name: Node.js Vulnerability Check - -on: [push, pull_request] - -jobs: - check-vulnerabilities: - runs-on: ubuntu-latest - - steps: - - name: Checkout repository - uses: actions/checkout@v4 - - - name: Use Node.js - uses: actions/setup-node@v4 - with: - node-version: '>=18.19.0' # Specify the Node.js version you want to test against - check-latest: true - - - name: Run Vulnerability Scan - run: npm audit --json - - - name: Fix Vulnerabilities - run: npm audit fix --force --json \ No newline at end of file