'Need deploy command in workflow for angular application to deploy node server in azure

I am Creating a angular application workflow build and deploy by using git hub actions and deploy in node server in azure. upto build process is completed need to add deploy command in workflow

Example for workflow. on: push: branches: - main

env: AZURE_WEBAPP_NAME: MY_WEBAPP_NAME
AZURE_WEBAPP_PACKAGE_PATH: '.'
NODE_VERSION: '14.x'

jobs: build: runs-on: ubuntu-latest steps: - uses: actions/checkout@v3

- name: Set up Node.js
  uses: actions/setup-node@v3
  with:
    node-version: ${{ env.NODE_VERSION }}
    cache: 'npm'

- name: npm install, build, and test
  run: |
    npm install
    npm run build --if-present
    npm run test --if-present
- name: Upload artifact for deployment job
  uses: actions/upload-artifact@v3
  with:
    name: node-app
    path: .

deploy: runs-on: ubuntu-latest needs: build environment: name: 'production' url: ${{ steps.deploy-to-webapp.outputs.webapp-url }}

steps:
- name: Download artifact from build job
  uses: actions/download-artifact@v3
  with:
    name: node-app

- name: 'Deploy to Azure WebApp'
  id: deploy-to-webapp 
  uses: azure/webapps-deploy@0b651ed7546ecfc75024011f76944cb9b381ef1e
  with:
    app-name: ${{ env.AZURE_WEBAPP_NAME }}
    publish-profile: ${{ secrets.AZURE_WEBAPP_PUBLISH_PROFILE }}
    package: ${{ env.AZURE_WEBAPP_PACKAGE_PATH }}


Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source