Skip to content

Commit

Permalink
try using a mongodb github action with a replica set
Browse files Browse the repository at this point in the history
  • Loading branch information
eeerin committed Aug 30, 2024
1 parent 153db01 commit be40721
Showing 1 changed file with 5 additions and 11 deletions.
16 changes: 5 additions & 11 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,21 +12,10 @@ jobs:
strategy:
matrix:
nodejs: [ '18', '20', '22' ]
runs-on: ubuntu-latest
container: ubuntu:latest
permissions:
actions: write
contents: read
pull-requests: write
services:
mongo:
image: mongo
options: >-
--bind_ip_all --replSet rs0
--health-cmd "echo "try { rs.status() } catch (e) { rs.initiate() }" | mongosh --quiet"
--health-interval 10s
--health-timeout 5s
--health-retries 5
steps:
- name: Cancel Previous Runs
uses: styfle/[email protected]
Expand All @@ -38,6 +27,11 @@ jobs:
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.nodejs }}
- name: Start MongoDB
uses: supercharge/[email protected]
with:
mongodb-version: '6.0'
mongodb-replica-set: rs0
- run: npm install -g [email protected]
- run: yarn install --frozen-lockfile
- run: yarn test

0 comments on commit be40721

Please sign in to comment.