Skip to content

Add Azure login step to deployment workflow; configure authentication… #3

Add Azure login step to deployment workflow; configure authentication…

Add Azure login step to deployment workflow; configure authentication… #3

name: Deploy to Azure Web App
on:
push:
branches: [ signup-with-google ]
env:
AZURE_WEBAPP_NAME: subtracker # Replace with your app name
NODE_VERSION: '18.x'
jobs:
build-and-deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up Node.js
uses: actions/setup-node@v2
with:
node-version: ${{ env.NODE_VERSION }}
- name: Install Dependencies
run: |
npm install
- name: Build Frontend
run: npm run build
- name: Login to Azure
uses: azure/login@v2
with:
client-id: ${{ secrets.AZUREAPPSERVICE_CLIENTID_15C4BE7710BB4A77BE73704527C4EC52 }}
tenant-id: ${{ secrets.AZUREAPPSERVICE_TENANTID_84C31CA0AC3B4EAEAD11519D80233E6f }}
subscription-id: ${{ secrets.AZUREAPPSERVICE_SUBSCRIPTIONID_302B8A3B565042929E707851B421FF06 }}
- name: Deploy to Azure Web App
uses: azure/webapps-deploy@v2
with:
app-name: ${{ env.AZURE_WEBAPP_NAME }}
publish-profile: ${{ secrets.AZURE_WEBAPP_PUBLISH_PROFILE }}
package: .