By default, Docker containers run as `root`. If an attacker compromises the app, they have root access to the container (and potentially the host). Running as a non-root user is a critical security best practice, mandated by policies like Azure Policy for Kubernetes. The Dockerfile Fix Key Takeaways You cannot bind to ports < 1024 […]
Read more βCategory: Emerging Technologies
Emerging technologies include a variety of technologies such as educational technology, information technology, nanotechnology, biotechnology, cognitive science, psychotechnology, robotics, and artificial intelligence.
.NET 6 Minimal APIs: First Look
.NET 6 introduces “Minimal APIs”, a stripped-down approach to building HTTP APIs without the ceremony of Controllers, Filters, or `Startup.cs`. Four Lines of Code Parameter Binding It infers binding from route, query, or body automatically. Key Takeaways Minimal APIs are **faster** than Controllers (less reflection overhead). You can still use DI, Auth, and Validation. Great […]
Read more βMassTransit: The Enterprise Service Bus for .NET
Don’t implement `RabbitMQ.Client` directly. It’s complex and error-prone. **MassTransit** abstracts the message broker (RabbitMQ, Azure Service Bus, SQS), providing a unified API for consumers, sagas, and fault tolerance. Defining a Consumer Configuration Key Takeaways MassTransit handles **Connection Recovery** and **Retry Policies** out of the box. Use **Sagas** for long-running stateful workflows.
Read more βBicep Modules: Enterprise Infrastructure Scale
Copy-pasting Bicep code defeats the purpose of Infrastructure as Code. **Modules** allow you to strictly define inputs and outputs for reusable components (like a standardized VNET or Storage Account), enforcing compliance across the enterprise. Creating a Module Consuming the Module Key Takeaways Publish modules to a **Private Bicep Registry** (ACR) for cross-team sharing. Use `br:myregistry.azurecr.io/bicep/storage:v1` […]
Read more βAzure Key Vault: Rotation Policies
Static secrets are a risk. “Key Rotation” limits the blast radius of a leak. Azure Key Vault now supports automated rotation for encryption keys, and we can build logic for secret rotation (e.g., SQL passwords). The Rotation Logic (Azure Functions) Key Takeaways Use **Managed Identity** so the rotation function itself needs no secrets. Implement the […]
Read more βC# 10 Preview: Global Usings
C# 10 (coming with .NET 6) aims to reduce file clutter. **Global Usings** allow you to define namespace imports once for the entire project. Manual Creation Create a file `GlobalUsings.cs`: Implicit Usings The SDK can do it for you based on project type. This automatically imports `System.Net.Http.Json`, `Microsoft.AspNetCore.Builder`, etc., in Web projects. Key Takeaways Reduces […]
Read more β