This tutorial shows you how to set up Duende IdentityServer with ASP.NET Core Identity from scratch, using MongoDB as the underlying database. We'll configure ASP.NET Core Identity to store client credentials in MongoDB. When a client requests authentication from IdentityServer, those credentials are validated directly against the MongoDB database through ASP.NET Core Identity.
By the end of this guide, you'll have a fully secured Web API protected by Duende IdentityServer — built entirely from the ground up.
The source codes are given in GitHub repository.
(more…)In this tutorial, we'll implement ASP.NET Core Identity with MongoDB as the database — replacing the default SQL Server setup. We'll start by configuring Identity to work with MongoDB, then build a sample project that creates Identity Users and Roles. Finally, we'll add Login and Logout functionality so users can authenticate and access secured parts of the website.
(more…)ZXing.NET is a library which supports decoding and generating of barcodes (like QR Code, PDF 417, EAN, UPC, Aztec, Data Matrix, Codabar) within images. In this tutorial I will implement it in ASP.NET Core application.
(more…)This tutorial explains JWT Refresh Tokens — what they are, how to generate them, and how they work together with JWT Access Tokens. By the time you're done, you should have a clear understanding of both access and refresh tokens. We'll also implement refresh tokens in our ASP.NET Core application, and you can grab the full source code from the download link at the end of this tutorial.
(more…)Kubernetes ensures that the App running in Pods is always healthy. If there is some problem with the App then it restarts the Pod based on the restart policy set for the Pod. The question now is how k8s detects an un-healthy app? The answer is through Probes. In this tutorial we will be creating ASP.NET Core Kubernetes Probes this will help you to maintain your app smoothly.
(more…)Deploying apps on Kubernetes could be a job full of problems so we need HELM. HELM is a superhero like “He-Man”.
(more…)In this ASP.NET Core Kubernetes tutorial we will be using Persistent Volumes (PV) as storages in the cluster, these are persistent in nature. The PV has a lifecycle independent of any individual pod which is using the PV. A Persistent Volume remains outside the Pod unlike emptyDir volume (emptyDir remains inside the Pod) so even if a Pod crashes there is no risk of the volume getting ruined.
(more…)We will now learn ASP.NET Core Kubernetes Volume and how to Mount SSL Certificates to Volume. A Kubernetes Volume is a directory, containing some files, which is accessible to all containers in a Pod. Files to this directory can be mounted from outside the Pod and so if the Pod or Containers crash then also this directory and it’s contents remain safe.
(more…)In this ASP.NET Core Kubernetes tutorial I will host a Multi-Container ASP.NET Core app to Multiple Kubernetes Pods. I will also add a Service to expose the pods. The Pods will use this service to communicate with one another.
In this ASP.NET Core Kubernetes Tutorial I will host a Multi-Container ASP.NET Core app to a single Kubernetes Pod. The ASP.NET Core app will have 2 containers and these containers will also communicate with each other. I will show you how this communication will take place inside the Pod.
(more…)