When testing my Cosmos database I often like to reset the containers, or in other words, delete all the existing documents. Unfortunately, there is no way to do a DELETE * FROM in Cosmos, at least not yet. I know I could create a Console Application or Azure Function to do this, but I was…
Category: Azure
Adventures with Bicep: How to Create an App Service for Containers
I wanted to create the following Azure resources: Azure Container Registry App Service Plan App Service The App Service would need to support Linux containers. I have been doing a lot with Bicep, with the following bicep file as my first attempt: When I ran my script the first time, it wasn’t setup for containers,…
Adventures with PowerShell: Add or Update Resource Tags
Whenever I deploy a release to Azure, using Azure DevOps, I like to add or update a tag with the current build version. To do this, I created a PowerShell script called UpdateTags.ps1. In full disclosure, transparency, and whatever other buzz words there are now for coming clean, I cobbled this script together from a…
Adventures with Azure DevOps: Connect to Azure Database for MySQL
I have been doing a lot around Azure DevOps as of late, and started dipping my toe into the CI/CD for databases, thought of calling it DataOps, but that doesn’t look like the correct term. Anyway, in my Azure DevOps pipeline I wanted to run a few tasks against an Azure Database for MySQL, e.g….
Adventures with Azure DevOps: Assembly Version Validation
I have a .NET 5 Web Api that I deploy using classic pipeline in Azure DevOps. When my Web Api is published I want to confirm that the correct version was really deployed, sometimes things happen where the deployment is successful but for some reason the older assembly might not be overwritten. In my Web…
Adventures with Bicep: Cosmos Connection Strings
I have been playing around with Azure Bicep for deploying my infrastructure to Azure. If you are new to Bicep, please take a look at Azure/bicep: Bicep is a declarative language for describing and deploying Azure resources (github.com). My challenge? I want to write Cosmos connection strings to Azure Key Vault. I am using Bicep…
Adventures in Azure: Naming Conventions
“There are only two hard things in Computer Science: cache invalidation and naming things.” — Phil Karlton When it comes to naming resources I always somewhat follow the guidance recommended at Recommended naming and tagging conventions – Cloud Adoption Framework | Microsoft Docs. Personally, I put more emphasis on tagging than naming, the tags can…
Adventures in Azure API Management: Pay Attention to Order in Policies
I was trying to secure an Azure API Management (APIM) APIs with OAuth 2.0 and Azure AD per Protect API backend in API Management using OAuth 2.0 and Azure AD – Azure API Management | Microsoft Docs. My APIM managed API calls a back-end .NET Core API secured with Managed Identity. In my policy, which…
Adventures in CosmosDB: New Date and Time System Functions
Been a little while since I last posted, but wanted to share with you a link to some exciting new features in CosmosDB around Date and Time System Functions. Enjoy!
Adventures with Azure ARM Templates: Create Logic App API Connection for Cosmos
With help from a teammate, I completed an ARM Template and PowerShell script to deploy a Cosmos API Connection for a Logic App to Azure. Thought I would share with everyone, in case you are curious on how to accomplish this. Download these two files and navigate to the directory and run the following script…