Skip to content

Clean project: remove documentation, diagrams, and log files #32

Clean project: remove documentation, diagrams, and log files

Clean project: remove documentation, diagrams, and log files #32

Workflow file for this run

name: CD Pipeline
on:
push:
branches: [main]
workflow_dispatch:
env:
ACR_NAME: flowopsacr2025.azurecr.io
BACKEND_IMAGE: flowopsacr2025.azurecr.io/flowops-backend
FRONTEND_IMAGE: flowopsacr2025.azurecr.io/flowops-frontend
BACKEND_URL: https://flowops-backend-app.azurewebsites.net
jobs:
build-and-deploy:
name: Build and Deploy Docker Images
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Login to Azure Container Registry
uses: docker/login-action@v3
with:
registry: ${{ env.ACR_NAME }}
username: ${{ secrets.ACR_USERNAME }}
password: ${{ secrets.ACR_PASSWORD }}
# Build and push Backend Docker image
- name: Build and Push Backend
uses: docker/build-push-action@v5
with:
context: ./backend
push: true
tags: |
${{ env.BACKEND_IMAGE }}:${{ github.sha }}
${{ env.BACKEND_IMAGE }}:latest
cache-from: type=gha
cache-to: type=gha,mode=max
# Build and push Frontend Docker image with API URL
- name: Build and Push Frontend
uses: docker/build-push-action@v5
with:
context: ./frontend
push: true
tags: |
${{ env.FRONTEND_IMAGE }}:${{ github.sha }}
${{ env.FRONTEND_IMAGE }}:latest
build-args: |
VITE_API_URL=${{ env.BACKEND_URL }}/api
cache-from: type=gha
cache-to: type=gha,mode=max
# Deploy Backend container to Azure App Service via Webhook
- name: Deploy Backend to Azure
run: curl -X POST "${{ secrets.AZURE_BACKEND_WEBHOOK }}"
# Deploy Frontend container to Azure App Service via Webhook
- name: Deploy Frontend to Azure
run: curl -X POST "${{ secrets.AZURE_FRONTEND_WEBHOOK }}"