Tuesday, 26 August 2025

Deploy Redis Insight on AKS to View/Update Data in Redis Cluster Deployed on AKS

 "Setup Redis Cluster with JSON and Search Modules on AKS with Binami Redis Using Custom Image" is explained in the prevous post. We can use redis insight to connect to redis cluster on AKS to explore data and add or update data. Let's look at how we can setup redis insight on AKS in this post.

The expectation is to have redis insight connected to redis clsuter on aks as shown below.


Thursday, 21 August 2025

PART2 - Using Bash Instead of PowerShell for - Setting Up Azure Managed Redis with Terraform Using AzApi

 We have discussed "Setting Up Azure Managed Redis with Terraform Using AzApi" , since direct terraform resources are not yet available until the pull request here is released. We used a PowerShell script to extract access key and output it from terraform output. In this post let's look at how to get the same steps with bash script instead of PowerShell and get the Azure Managed Redis deployed as shown below.



Tuesday, 19 August 2025

Setting Up Azure Managed Redis with Terraform Using AzApi

 The new Azure Managed Redis can be deployed with balanced compute and memory with high availability, and useful modules such as RedisJson and RedisSearch. This is really a useful and good pricing options to use Redis as a managed service in Azure. Note that it is not the enterprise redis offering in Azure and managed redis for Azure has more flexible pricing options. However, terraform support for this is yet to be added and will be available in another month or so as per the pull request here. Let's see how to get a Azure Managed Redis deployed with terraform for no using AzAPI.

The expectaion is to have a deployed Azure Managed Redis as shown below.

Wednesday, 13 August 2025

Setup Redis Cluster with JSON and Search Modules on AKS with Binami Redis Using Custom Image

 We have discussed "Build Custom Docker Images with Redis Json and Search Module Support for deploying Bitnami Redis Cluster and Standalone in AKS" previously. We have cfreated a cutom redis cluster image including the redis modules json, search etc. In this post let's explore how to setup Redis cluster on AKS using binami helm chart, while using the custom built image. The usage of custom built image is required to have the json and search modules available as described in the post "Build Custom Docker Images with Redis Json and Search Module Support for deploying Bitnami Redis Cluster and Standalone in AKS".

Note that the redis cluster deployed to AKS or to kubernetes can be only accessed withing the kubernetes cluster. Therefore, only the apps deployed to AKS/kubernetes can only access the redis endpoint in redis cluster on AKS. For allowing local development with redis on AKS, we need to setup bitnami redis standalone mode, which we will discuss in a future post.

Thursday, 31 July 2025

Build Custom Docker Images with Redis Json and Search Module Support for deploying Bitnami Redis Cluster and Standalone in AKS

 Redis cluster deployed in AKS (kubernetes) is a really useful way to use Redis cache in dotnet projects. To depoy Redis on AKS we can use Redis bitnami cluster or standalone. Cluster mode deployment is only accessible within the kubernetes clsuter, therefore for development environments, to allow local machine access to Redis in an AKS clsuter you need the standalone mode of deployment, which we will discuss in the next post. The bitnnami Redis images are not included with the json module and search module which are useful to store json documents and search them in a Redis setup. In this post let's explore how to include addtional modules in Bitnami Redis to build a custom image so that the Json and Search of Redis available in AKS once deployed.

The expection is to build custom Bitnami Redis images with module support similar to Redis 8 and get them added to Azure Container registry as shown below.


 

Wednesday, 30 July 2025

Use Directory.Packages.props to Centralize Version Management of Consumed NuGet Packages in a .NET Solution

 Using NueGet packages and keep the versions upto date is a requirement as well as a challange if the versions are defined all over in many projects, in a given dotnet solution. We can limit the reference to packages to refer only in one project for a solution as consuming projects will inherently get the references. However, when it comes to using unit test projects we must reference the packages in all test projects to ensure test dicoverability in pipelines as well as in Test Explorer of the Visual Studio. Therefore, centralize Nuget Package management is essential in a complex and large solutions.

The Directory.Packages.props is the saviour for this requirement which allows us to define all the package versions centrally in the solution, by adding a Directory.Packages.props to the root of the repo, similar to using nuget.config.


Tuesday, 22 July 2025

Use DefaultAzureCredential with C# to Work with Azure Cosmos DB Data Using "Cosmos DB Built-in Data Contributor" RBAC

 We have discussed "Add Cosmos DB Built-in Roles to Resource Identities via Terraform to Allow Role Based Access to Data in Cosmos DB" in the previous post. Now that the data constributor roles are setup in Azure Cosmos DB, let's look at how to write a simple code to access,  create Cosmos DB data using DefaultAzureCredential with C#.

The expection is to get document data created in Cosmos DB as similar to shown below.



Wednesday, 16 July 2025

Add Cosmos DB Built-in Roles to Resource Identities via Terraform to Allow Role Based Access to Data in Cosmos DB

 Azure Cosmos DB can be used with DefaultAzureCrentials in C#. However, for enabling usage of DefaultAzureCrentials  with Azure Cosmos DB requires special data roles to be added to the  Cosmos DB account. There are two built in roles data reader and data contributor. Unlike other RBAC roles in Azure these roles cannot be assigned via Azure portal and they must be added programatically. They have to added via Azure CLI, Bicep, Powershell, REST API or Terraform.

Popular Posts