From bb976b69686ff6f5e03e4a45a1088b8155b87d8b Mon Sep 17 00:00:00 2001 From: Vidyadevi Salunkhe <84471226+Vidyaaa24@users.noreply.github.com> Date: Wed, 20 Sep 2023 16:25:34 +0530 Subject: [PATCH] Create package-prod.yml --- .github/workflows/package-prod.yml | 45 ++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) create mode 100644 .github/workflows/package-prod.yml diff --git a/.github/workflows/package-prod.yml b/.github/workflows/package-prod.yml new file mode 100644 index 00000000..04f0cbf7 --- /dev/null +++ b/.github/workflows/package-prod.yml @@ -0,0 +1,45 @@ +name: Package Prod + +on: + push: + branches: [ "master"] + +jobs: + Package: + runs-on: ubuntu-latest + permissions: + actions: read + contents: read + security-events: write + + strategy: + fail-fast: false + + steps: + - name: Checkout code + uses: actions/checkout@v3 + + - name: Set up Java + uses: actions/setup-java@v3 + with: + java-version: '8' + distribution: 'adopt' + + - name: Set up Node.js + uses: actions/setup-node@v2 + with: + node-version: 16 + + - name: Build with Yarn | NPM and Create WAR file + run: | + yarn config set legacy-peer-deps true + yarn global add node-gyp + yarn add node-sass --force + yarn install --force + npm run ng build --prod --aot && grunt + + - name: Upload WAR file as artifact + uses: actions/upload-artifact@v2 + with: + name: Helpline1097-UI + path: target/