Skip to content

readme update, again? #29

readme update, again?

readme update, again? #29

on:
push:
branches:
- master
name: Infrastructure
jobs:
changes:
name: Check changes
runs-on: ubuntu-latest
outputs:
src: ${{ steps.changes.outputs.build }}
steps:
- uses: actions/checkout@v3
- uses: dorny/paths-filter@v2
id: changes
with:
filters: |
build:
- 'infrastructure/**'
- '.github/workflows/infrastructure.yaml'
build-and-deploy:
name: Deploy Infrastructure
needs: changes
if: ${{ needs.changes.outputs.src == 'true' }}
runs-on: ubuntu-latest
environment:
name: Production
steps:
# Checkout code
- uses: actions/checkout@main
# Log into Azure
- uses: azure/login@v1
with:
creds: ${{ secrets.AZURE_CREDENTIALS }}
# Deploy Bicep file
- name: deploy
uses: azure/arm-deploy@v1
with:
scope: 'subscription'
region: 'westeurope'
subscriptionId: ${{ secrets.AZURE_SUBSCRIPTION }}
template: infrastructure/main.bicep
parameters: 'projectName=${{ secrets.PROJECTNAME }} location=westeurope linkPreviewApiKey=${{ secrets.LINK_PREVIEW_API_KEY }}'
failOnStdErr: false