Git Product home page Git Product logo

dotnet-is4-postgres-fullstack-quickstart's Introduction

.NET Identity Server 4 Quickstart

Full stack .NET 6 PostgreSQL backend with identity server 4 + is4 Skoruba admin.

Prerequisites

  1. Docker
  2. Linux OS x64
  3. Yarn

Running

  1. Run in frontend (for proto)
cd frontend
yarn install
  1. Copy config.example.yml to config.yml.
  2. Run
./manage.py run dev
./manage.py build prod
./manage.py push prod

Just open http://172.17.0.1:2020 and enter the admin username/password in config.yml. Add user, then login in http://172.17.0.1:2022.
You can access swagger on http://172.17.0.1:2025/swagger.
You might need to add client Redirect URI and CORS in PhpPgAdmin http://172.17.0.1:2024:

Configuration

  1. Config everything in config.yml.
  2. Add your redirect URI for your domain (/signin-oidc) in phppgadmin > is4admin > ClientRedirectUris for ClientId skoruba_identity_admin

Changed from the original version:

https://github.com/skoruba/IdentityServer4.Admin/blob/master/docs/Configure-Ubuntu-PostgreSQL-Tutorial.md

  1. Admin setting (IdentityServer4.Admin-release-2.1.0/src/Skoruba.IdentityServer4.Admin/appsettings.json):
  • Changed database
"DatabaseProviderConfiguration": {
    "ProviderType": "PostgreSQL"
},
  • Changed db string connection
Server=localhost; User Id=postgres; Database=is4admin; Port=5432; Password=postgres; SSL Mode=Prefer; Trust Server Certificate=true

  1. Added timezone options for postgres in main func
  • IdentityServer4.Admin-release-2.1.0/src/Skoruba.IdentityServer4.Admin/Program.cs
  • IdentityServer4.Admin-release-2.1.0/src/Skoruba.IdentityServer4.Admin.Api/Program.cs
  • IdentityServer4.Admin-release-2.1.0/src/Skoruba.IdentityServer4.STS.Identity/Program.cs
AppContext.SetSwitch("Npgsql.EnableLegacyTimestampBehavior", true);
  • Added password grant type
  • IdentityServer4.Admin-release-2.1.0/src/Skoruba.IdentityServer4.Admin/identityserverdata.json
"Clients": [
    {
        ...
        "AllowedGrantTypes": [
            "authorization_code",
            "password"
        ],
        ...
    }
]

dotnet-is4-postgres-fullstack-quickstart's People

Contributors

vmasdani avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.