diff --git a/README.md b/README.md index 80fcefc0..0c3b633b 100644 --- a/README.md +++ b/README.md @@ -1 +1,31 @@ -# Keycloak.Net \ No newline at end of file +![Icon](https://i.imgur.com/eEjfRLz.jpg?2) +# Keycloak.Net +[![Build status](https://ci.appveyor.com/api/projects/status/c9npduu2dp9ljlps?svg=true)](https://ci.appveyor.com/project/lvermeulen/keycloak-net) + [![license](https://img.shields.io/github/license/lvermeulen/Keycloak.Net.svg?maxAge=2592000)](https://github.com/lvermeulen/Keycloak.Net/blob/master/LICENSE) [![NuGet](https://img.shields.io/nuget/v/Keycloak.Net.svg?maxAge=2592000)](https://www.nuget.org/packages/Keycloak.Net/) + ![](https://img.shields.io/badge/.net-4.5.2-yellowgreen.svg) ![](https://img.shields.io/badge/netstandard-1.4-yellowgreen.svg) + +Client for [Keycloak](https://www.keycloak.org/) 6.x + +## Features +* [ ] Attack Detection +* [ ] Authentication Management +* [ ] Client Attribute Certificate +* [ ] Client Initial Access +* [ ] Client Registration Policy +* [ ] Client Role Mappings +* [ ] Client Scopes +* [ ] Clients +* [ ] Component +* [ ] Groups +* [ ] Identity Providers +* [ ] Key +* [ ] Protocol Mappers +* [ ] Realms Admin +* [ ] Role Mapper +* [ ] Roles +* [ ] Roles (by ID) +* [ ] Scope Mappings +* [ ] User Storage Provider +* [ ] Users +* [ ] Root + diff --git a/appveyor.yml b/appveyor.yml new file mode 100644 index 00000000..700b8611 --- /dev/null +++ b/appveyor.yml @@ -0,0 +1,28 @@ +version: 1.0.0-{build} +branches: + only: + - master +pull_requests: + do_not_increment_build_number: true +image: Visual Studio 2019 +build_script: +- ps: .\build\build.ps1 $env:APPVEYOR_BUILD_VERSION $env:APPVEYOR_REPO_TAG_NAME +#before_test: +#- ps: $blockRdp = $true; iex ((new-object net.webclient).DownloadString('https://raw.githubusercontent.com/appveyor/ci/master/scripts/enable-rdp.ps1')) +#test_script: +#- ps: | +# if ($true) +# { +# .\build\test.ps1 +# } +artifacts: +- path: '.\artifacts\*.nupkg' +deploy: +- provider: NuGet + api_key: + secure: Uft/AgWL0ObDUb6hWLhsftRR1sNhLa5vONUcVa/2KjVAYZApxZD6ckJ+ABFQs3bB + skip_symbols: true + artifact: /.*\.nupkg/ + on: + branch: master # release from master branch only + appveyor_repo_tag: true # deploy on tag push only diff --git a/build/build.ps1 b/build/build.ps1 new file mode 100644 index 00000000..12c945c8 --- /dev/null +++ b/build/build.ps1 @@ -0,0 +1,25 @@ +param ( + [string]$BuildVersionNumber=$(throw "-BuildVersionNumber is required."), + [string]$TagVersionNumber +) + +& dotnet restore --no-cache + +foreach ($src in ls $PSScriptRoot\..\src/*) { + Push-Location $src + + Write-Output "build: Building & packaging project in $src" + + if ($TagVersionNumber -ne $null) { + $version = $TagVersionNumber + } + else { + $version = $BuildVersionNumber + } + + & dotnet build -c Release + & dotnet pack -c Release --include-symbols -o ..\..\artifacts --no-build /p:PackageVersion=$version + if($LASTEXITCODE -ne 0) { exit 1 } + + Pop-Location +} diff --git a/build/test.ps1 b/build/test.ps1 new file mode 100644 index 00000000..b70884f2 --- /dev/null +++ b/build/test.ps1 @@ -0,0 +1,11 @@ +foreach ($test in ls $PSScriptRoot\..\test/*) { + Push-Location $test + + Write-Output "build: Testing project in $test" + + & dotnet restore --no-cache + & dotnet test + if($LASTEXITCODE -ne 0) { exit 1 } + + Pop-Location +} diff --git a/global.json b/global.json new file mode 100644 index 00000000..282a67b8 --- /dev/null +++ b/global.json @@ -0,0 +1,6 @@ +{ + "projects": [ "src", "test" ], + "sdk": { + "version": "1.1.13" + } +} \ No newline at end of file