Skip to content

Commit b2cff10

Browse files
Update the documentation
1 parent 6616301 commit b2cff10

3 files changed

Lines changed: 70 additions & 0 deletions

File tree

Lines changed: 63 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,63 @@
1+
# Migrating from Duende to SimpleIdServer
2+
3+
If you're currently using Duende IdentityServer version 7, migrating to SimpleIdServer is a smooth and straightforward process.
4+
With the help of our migration tool, you can quickly transition your identity server without hassle.
5+
6+
## How to Migrate
7+
8+
To begin the migration, you will need to install the `SimpleIdServer.IdServer.Migrations.Duende` NuGet package on your identity server.
9+
This package provides the necessary tools to facilitate the migration from Duende to SimpleIdServer.
10+
11+
```cmd title="cmd.exe"
12+
dotnet add package SimpleIdServer.IdServer.Migrations.Duende
13+
```
14+
15+
Once the NuGet package is installed, follow these steps to configure your migration:
16+
17+
Edit the Program.cs file; Add two essential functions:
18+
19+
* **EnableMigration**: This function registers the dependencies needed to execute the migration.
20+
21+
* **AddDuendeMigration** : This function registers the dependencies for migrating data from a Duende database to a SimpleIdServer database. It takes a lambda expression as a parameter, where you can specify the database connection string.
22+
23+
Here's an example of how to configure the migration:
24+
25+
```csharp title="Program.cs"
26+
builder.AddSidIdentityServer()
27+
.EnableMigration()
28+
.AddDuendeMigration(a =>
29+
{
30+
a.UseSqlServer(""); // Add your connection string here
31+
});
32+
```
33+
34+
## Running the Migration
35+
36+
Once the migration is set up, you can execute it in two ways:
37+
38+
1. **Manual Execution via Admin Portal**: You can trigger the migration manually by navigating to the `Migrations` tab in the administration portal of your identity server.
39+
40+
![Authenticate](./imgs/migrations.png)
41+
42+
2. **Automatic Execution on Server Startup**: If you want the migration to run automatically when the identity server starts, you can call the `LaunchMigration` function. This function takes a parameter, the realm, which determines where the data will be migrated. By default, this value is set to `master`.
43+
44+
Example :
45+
46+
```csharp title="Program.cs"
47+
app.Services.LaunchMigration();
48+
```
49+
50+
## Entities Migrated
51+
52+
The following entities will be migrated from Duende IdentityServer to SimpleIdServer:
53+
54+
| Duende Entity | SimpleIdServer Entity |
55+
| ----------------- | --------------------- |
56+
| ApiScopes | Scope |
57+
| IdentityResources | Scope |
58+
| ApiResource | ApiResource |
59+
| Client | Client |
60+
| Groups | Groups |
61+
| Users | Users |
62+
63+
With this migration process, your identity server's data is transferred seamlessly to SimpleIdServer, ensuring minimal disruption and a smooth transition.
65.4 KB
Loading

website/sidebars.js

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -100,6 +100,13 @@ const sidebars = {
100100
'idserver/hosting/nginx',
101101
'idserver/hosting/loadbalancing'
102102
]
103+
},
104+
{
105+
type: 'category',
106+
label: 'Migrations',
107+
items: [
108+
'idserver/migrations/duende'
109+
]
103110
}
104111
]
105112
},

0 commit comments

Comments
 (0)