From cb07b6a8415a3c2928f6042312e7cc1f847cabef Mon Sep 17 00:00:00 2001 From: Chris Patterson Date: Wed, 3 Jun 2020 09:52:23 -0400 Subject: [PATCH] Using workflow scoped working-directory --- .github/workflows/mongodb-service.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/mongodb-service.yml b/.github/workflows/mongodb-service.yml index 6207eb2..51fbd33 100644 --- a/.github/workflows/mongodb-service.yml +++ b/.github/workflows/mongodb-service.yml @@ -7,7 +7,11 @@ on: pull_request: branches: - master - + +defaults: + run: + working-directory: ./mongodb + jobs: container-job: runs-on: ubuntu-latest @@ -22,13 +26,11 @@ jobs: image: mongo ports: - 27017:27017 - + steps: - uses: actions/checkout@v1 - run: npm ci - working-directory: ./mongodb - run: node client.js - working-directory: ./mongodb env: # use mongodb for the host here because we have specified a container for the job. # If we were running the job on the VM this would be localhost @@ -50,9 +52,7 @@ jobs: steps: - uses: actions/checkout@v1 - run: npm ci - working-directory: ./mongodb - run: node client.js - working-directory: ./mongodb env: # use localhost for the host here because we are running the job on the VM. # If we were running the job on in a container this would be mongodb