From 59c201c23ba335a5e4eec521ba3cd371d7701e02 Mon Sep 17 00:00:00 2001 From: Tim Warner Date: Wed, 7 Aug 2024 09:19:02 -0500 Subject: [PATCH] chore: Update O'Reilly Artifact Demo workflow name --- .github/workflows/oreilly-artifact-demo.yml | 2 +- .github/workflows/oreilly-node-app-build.yml | 50 ++++++++++++++++++++ 2 files changed, 51 insertions(+), 1 deletion(-) diff --git a/.github/workflows/oreilly-artifact-demo.yml b/.github/workflows/oreilly-artifact-demo.yml index 2953272..67c611f 100644 --- a/.github/workflows/oreilly-artifact-demo.yml +++ b/.github/workflows/oreilly-artifact-demo.yml @@ -1,4 +1,4 @@ -name: O'Reilly Artifact Demo +name: O'Reilly Artifact Demo Test on: push: diff --git a/.github/workflows/oreilly-node-app-build.yml b/.github/workflows/oreilly-node-app-build.yml index e69de29..63ed2c5 100644 --- a/.github/workflows/oreilly-node-app-build.yml +++ b/.github/workflows/oreilly-node-app-build.yml @@ -0,0 +1,50 @@ +name: OReilly Test and Build Node App Workflow + +on: + workflow_dispatch: + +jobs: + build: + runs-on: ubuntu-latest + steps: + - name: Checkout repository + uses: actions/checkout@v3 + + - name: Set up Node.js + uses: actions/setup-node@v3 + with: + node-version: '16' + + - name: Install dependencies + run: npm ci + working-directory: ./node-app + + - name: Run tests + run: npm test + working-directory: ./node-app + + - name: Build app + run: npm run build + working-directory: ./node-app + + - name: Upload build artifacts + uses: actions/upload-artifact@v3 + with: + name: node-app-build + path: ./node-app/dist + + download: + needs: build + runs-on: ubuntu-latest + steps: + - name: Checkout repository + uses: actions/checkout@v3 + + - name: Download build artifacts + uses: actions/download-artifact@v3 + with: + name: node-app-build + path: ./node-app/dist + + - name: Display artifact contents + run: ls -la ./node-app/dist \ No newline at end of file