Refactor Settings
Settings for the server are now combined with the settings from the SDK. This introduces a large breaking change and a migration should be created. This refactor utilizes .NET Configuration and the Options pattern. This will allow for the overriding of any setting using envionment variables. It also means that Settings.yml can be used to override any .NET configuration. A SettingsProvider implementation was created, and any updating of settings was changed from SettingsService.SaveSettings() to SettingsProvider.Update(s => { ... })
This commit is contained in:
parent
f20d2861bb
commit
add770b227
188 changed files with 1271 additions and 919 deletions
|
|
@ -12,8 +12,6 @@ namespace LANCommander.Migrations
|
|||
/// <inheritdoc />
|
||||
protected override void Up(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
var settings = SettingService.GetSettings();
|
||||
|
||||
// Migrate any old icons from the filesystem
|
||||
if (Directory.Exists("Icon"))
|
||||
foreach (var file in Directory.EnumerateFiles("Icon"))
|
||||
|
|
|
|||
|
|
@ -12,8 +12,6 @@ namespace LANCommander.Migrations
|
|||
/// <inheritdoc />
|
||||
protected override void Up(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
var settings = SettingService.GetSettings();
|
||||
|
||||
if (Directory.Exists("Media"))
|
||||
{
|
||||
var files = Directory.EnumerateFiles("Media");
|
||||
|
|
|
|||
|
|
@ -13,8 +13,6 @@ namespace LANCommander.Migrations
|
|||
/// <inheritdoc />
|
||||
protected override void Up(MigrationBuilder migrationBuilder)
|
||||
{
|
||||
var settings = SettingService.GetSettings();
|
||||
|
||||
migrationBuilder.AddColumn<Guid>(
|
||||
name: "StorageLocationId",
|
||||
table: "Media",
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue