Skip to content

Commit

Permalink
Fix dependency vulnerabilities
Browse files Browse the repository at this point in the history
  • Loading branch information
ScottKayeNeo committed Jan 6, 2025
1 parent b764e22 commit 9a28083
Show file tree
Hide file tree
Showing 7 changed files with 10,568 additions and 6,138 deletions.
18 changes: 4 additions & 14 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,21 +11,11 @@ jobs:
- uses: actions/setup-node@v2
with:
node-version: 18
- name: Get yarn cache
id: yarn-cache
run: echo "::set-output name=dir::$(yarn cache dir)"
- name: Cache node modules
uses: actions/cache@v4
with:
path: ${{ steps.yarn-cache.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
- name: Install
run: yarn --prefer-offline --frozen-lockfile --no-progress --non-interactive
run: npm ci
- name: Lint
run: yarn lint
run: npm run lint
- name: Build
run: yarn build
run: npm run build
- name: Test
run: yarn test
run: npm run test
14 changes: 2 additions & 12 deletions .github/workflows/publish.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,20 +23,10 @@ jobs:
- uses: actions/setup-node@v2
with:
node-version: 18
- name: Get yarn cache
id: yarn-cache
run: echo "::set-output name=dir::$(yarn cache dir)"
- name: Cache node modules
uses: actions/cache@v4
with:
path: ${{ steps.yarn-cache.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
- name: Install
run: yarn --prefer-offline --frozen-lockfile --no-progress --non-interactive
run: npm ci
- name: Test
run: yarn test
run: npm run test
- name: Coverage
uses: neofinancial/coverage-upload-action@0ffd2ee97816db805bdedcca37bcac50b9521f37
with:
Expand Down
22 changes: 6 additions & 16 deletions .github/workflows/pull-request.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,36 +11,26 @@ jobs:
- uses: actions/setup-node@v2
with:
node-version: 18
- name: Get yarn cache
id: yarn-cache
run: echo "::set-output name=dir::$(yarn cache dir)"
- name: Cache node modules
uses: actions/cache@v4
with:
path: ${{ steps.yarn-cache.outputs.dir }}
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
${{ runner.os }}-yarn-
- name: Install
run: yarn --prefer-offline --frozen-lockfile --no-progress --non-interactive
run: npm ci
- name: Lint
run: yarn lint
run: npm run lint
- name: Build
run: yarn build
run: npm run build
- name: Test
run: yarn test
run: npm run test
- name: Validate
uses: ./
with:
db-connection-env-var: MONGO_CONNECTION_STRING
run-command: yarn ci:validate
run-command: npm run ci:validate
binary-version: 4.4.6
instance-dbName: validation
instance-port: 27018
instance-storageEngine: wiredTiger
mongoms-debug: 1
- name: Package
run: yarn package
run: npm run package
- name: Import GPG key
uses: crazy-max/ghaction-import-gpg@e00cb83a68c1158b29afc5217dd0582cada6d172
with:
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ In your .github/workflows folder, add a new job step to the appropriate workflow
- uses: neofinancial/[email protected]
with:
db-connection-env-var: MONGODB_CONNECTION_STRING
run-command: yarn use:database
run-command: npm run use:database
binary-version: 4.4.6
instance-dbName: validation
instance-port: 27017
Expand All @@ -40,7 +40,7 @@ In your .github/workflows folder, add a new job step to the appropriate workflow

## Implementation

In the example, the **`run-command`** parameter value ("`yarn use:database`") is executed synchronously by the action using a child process. That script is therefore responsible for reading the ENV variable `MONGODB_CONNECTION_STRING` and configuring MongoDB client(s) accordingly.
In the example, the **`run-command`** parameter value ("`npm run use:database`") is executed synchronously by the action using a child process. That script is therefore responsible for reading the ENV variable `MONGODB_CONNECTION_STRING` and configuring MongoDB client(s) accordingly.

The memory-server is stopped (and destroyed) subsequent to the completion of this command, so the command's process should encompass all interactions with it.

Expand Down
145 changes: 134 additions & 11 deletions build/index.js

Large diffs are not rendered by default.

Loading

0 comments on commit 9a28083

Please sign in to comment.