A product management microservice done in ASP.NET Core 6
- Use GitHub Actions to deploy to Azure App Service.
- Containerize the API.
- Use GitHub Action to deploy to Azure Container Instances.
đź’ˇ Start/Stop slot in GitHub actions
Couldn't really find an action to do this, but can do this using an Azure CLI command.
# start the slot
az resource invoke-action --action start --ids /subscriptions/${{ secrets.AZURE_SUBSCRIPTION_ID }}/resourceGroups/${{ env.RG_NAME }}/providers/Microsoft.Web/sites/api-${{ env.APP_NAME }}-dev/slots/staging
# stop the slot
az resource invoke-action --action stop --ids /subscriptions/${{ secrets.AZURE_SUBSCRIPTION_ID }}/resourceGroups/${{ env.RG_NAME }}/providers/Microsoft.Web/sites/api-${{ env.APP_NAME }}-dev/slots/staging