Skip to content

Custom Identity API based on "ASP.Net Web API" template with usage of latest .Net and C#

dotnet-fizzyy/ASP.Net-Identity

Repository files navigation

About The Project

Note: This project is a non-commercial application based on authors personal interests of technologies.

This project represents application that is responsible for handling users and related to them entities.

Built With

Prerequisites

Before launching this application make sure you have prepared the following components:

Installation and launch

  1. Clone repository:
    git clone https://github.com/dotnet-fizzyy/ASP.Net-Identity.git
  2. Execute the following command to configure git hooks for repository: git config --local core.hooksPath .githooks/. If you use Linux/MacOS, make sure you have enough permissions to run hooks, execute the following command: sudo chmod +x .githooks/*.
  3. Run DY.Auth.Identity.Api.sln in the root directory;
  4. Depending on your OS, choose IIS or Kestrel as hosting webserver;
  5. Make sure your MSSQL database instance is running. Otherwise you will not be able to launch app;
  6. Start the application;
  7. Visit the following URL: https://localhost:{port}/swagger. You should be able to see Swagger description;

Docker launch

Docker is not necessary to launch application if you have prepared prerequisites for your physical OS. If you want to launch it without and modifications and would like to see the working result, you can refer to the next steps:

  1. Follow the first step from previous article;
  2. Switch open project root directory via terminal;
  3. Run the following command:
    docker-compose -f docker-compose.app.yml -f docker-compose.infrastructure.yml up --build
    
  4. Wait until corresponding images will be downloaded, all steps from Dockerfile will pass and application will start;
  5. Visit the following URL: http://localhost:13501/swagger. You should be able to see Swagger description;
  6. If you need to stop Docker containers, you can just press ctrl + C keyboard combination in your terminal and wait until containers will be stopped. To terminate containers, enter (or stop via Docker dashboard):
    docker-compose down
    
  7. To remove application images, enter the following command (or remove via Docker dashboard):
    docker rmi mcr.microsoft.com/mssql/server identitywebapi nginx jaegertracing/all-in-one
    

Logging

Application does not write logs to files, it display logs in terminal in the following ways:

  1. Local run via IDE;
  2. Docker;

Tracing

Application supports tracing with help of Open Telemetry framework. In order to view traces you can use Jaeger UI tool provided in docker-compose.yml or set up it on your host. To be able to view traces after running application and Jaeger UI enter http://localhost:16686 URL in browser.

Usage

For more examples, please, refer to the following options:

Contact

dotnet-fizzyy | GitHub | [email protected]

About

Custom Identity API based on "ASP.Net Web API" template with usage of latest .Net and C#

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages