feat(ui,api): demo polish — 5 issues fixed for hackathon recording #109
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Deploy | |
| on: | |
| push: | |
| branches: [main] | |
| workflow_dispatch: | |
| concurrency: | |
| group: deploy-${{ github.ref }} | |
| cancel-in-progress: false | |
| env: | |
| REGISTRY: blueflamecr.azurecr.io | |
| API_IMAGE: blueflamecr.azurecr.io/blueflame-api | |
| WEB_IMAGE: blueflamecr.azurecr.io/blueflame-web | |
| jobs: | |
| build: | |
| name: Build & Test | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 15 | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: 20 | |
| cache: npm | |
| - name: Install dependencies | |
| run: npm ci | |
| - name: Build | |
| run: npx turbo build | |
| - name: Test | |
| run: npx turbo test | |
| deploy-api: | |
| name: Deploy API | |
| needs: build | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 15 | |
| environment: production | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| - name: Login to Azure | |
| uses: azure/login@v2 | |
| with: | |
| creds: ${{ secrets.AZURE_CREDENTIALS }} | |
| - name: Login to ACR | |
| run: az acr login --name blueflamecr | |
| - name: Build and push API image | |
| uses: docker/build-push-action@v6 | |
| with: | |
| context: . | |
| file: apps/api/Dockerfile | |
| push: true | |
| tags: | | |
| ${{ env.API_IMAGE }}:${{ github.sha }} | |
| ${{ env.API_IMAGE }}:latest | |
| - name: Deploy to Container Apps | |
| run: | | |
| az containerapp update \ | |
| --name blueflame-api-dev \ | |
| --resource-group ${{ vars.AZURE_RESOURCE_GROUP }} \ | |
| --image ${{ env.API_IMAGE }}:${{ github.sha }} | |
| deploy-web: | |
| name: Deploy Web | |
| needs: build | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 15 | |
| environment: production | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| - name: Login to Azure | |
| uses: azure/login@v2 | |
| with: | |
| creds: ${{ secrets.AZURE_CREDENTIALS }} | |
| - name: Login to ACR | |
| run: az acr login --name blueflamecr | |
| - name: Build and push Web image | |
| uses: docker/build-push-action@v6 | |
| with: | |
| context: . | |
| file: apps/web/Dockerfile | |
| push: true | |
| tags: | | |
| ${{ env.WEB_IMAGE }}:${{ github.sha }} | |
| ${{ env.WEB_IMAGE }}:latest | |
| - name: Deploy to Container Apps | |
| run: | | |
| az containerapp update \ | |
| --name blueflame-web-dev \ | |
| --resource-group ${{ vars.AZURE_RESOURCE_GROUP }} \ | |
| --image ${{ env.WEB_IMAGE }}:${{ github.sha }} |