GithubHelp home page GithubHelp logo

spudmashmedia / identityserver4.contrib.awsdynamodb Goto Github PK

View Code? Open in Web Editor NEW
11.0 7.0 3.0 40 KB

AWS DynamoDB Operation & Persisted store for IdentityServer4

License: MIT License

C# 66.86% PowerShell 7.22% Shell 7.45% Python 13.76% HCL 4.71%

identityserver4.contrib.awsdynamodb's Introduction

IdentityServer4.Contrib.AwsDynamoDB

Build status NuGet

Summary

AWS DynamoDB Operational & Persisted store for IdentityServer4

Installation

AWS Setup

Credentials

https://docs.aws.amazon.com/cli/latest/userguide/cli-config-files.html

AWS CLI

See https://docs.aws.amazon.com/cli/latest/userguide/cli-chap-getting-started.html

Generating DynamoDB Tables

See Tools | DynamoDB | Python | Readme.md

Nuget Package

Install-Package IdentityServer4.Contrib.AwsDynamoDB

Quick Setup

Startup.cs

    public void ConfigureServices(IServiceCollection services)
    {
        services.AddMvc();

        // 1) setup all services (Also sets up PersistedGrant Store)
        services.AddIs4DynamoDB(Configuration);
        
        // 2) Use ClientRepository + ResourceRepository
        services.AddIdentityServer()
                .AddDeveloperSigningCredential()
                .AddTestUsers(TestUsers.Users)
                .AddClientStore<ClientRepository>()
                .AddResourceStore<ResourceRepository>();
        
        Setup.SeedDynamoDB(
            services,
            Configuration,
            Clients.Get(),
            Resources.GetApiResources(),
            Resources.GetIdentityResources()
        );
    }

appsettings.json

{
  "AWS": {
    "Region": "[region]"
  },
  "IdentityServer4.Contrib.AwsDynamoDB": {
    "TableNamePrefix": "[prefix]"
  }
}
Field Value
[region] AWS region code. E.g. ap-southeast-2
[prefix] This value will prefix the POCO tables. E.g. Development- will be prefixed to Client DynamoDB table name as Development-Client

License

MIT

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.