增加上传华为云obs接口
This commit is contained in:
@@ -14,6 +14,7 @@
|
||||
<PackageReference Include="Microsoft.AspNetCore.Mvc.NewtonsoftJson" Version="5.0.5" />
|
||||
<PackageReference Include="Microsoft.Data.SqlClient" Version="3.0.0" />
|
||||
<PackageReference Include="Microsoft.Extensions.Configuration" Version="6.0.0-preview.1.21102.12" />
|
||||
<PackageReference Include="OnceMi.AspNetCore.OSS" Version="1.1.9" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
|
||||
@@ -8,6 +8,7 @@ using Microsoft.AspNetCore.Hosting;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
using Microsoft.Extensions.DependencyInjection;
|
||||
using Microsoft.Extensions.Hosting;
|
||||
using OnceMi.AspNetCore.OSS;
|
||||
using Serilog;
|
||||
using System.Text.Json;
|
||||
using System.Threading.Tasks;
|
||||
@@ -67,6 +68,7 @@ namespace Ewide.Web.Core
|
||||
// 设置雪花id的workerId,确保每个实例workerId都应不同
|
||||
//var workerId = ushort.Parse(App.Configuration["SnowId:WorkerId"] ?? "1");
|
||||
//IDGenerator.SetIdGenerator(new IDGeneratorOptions { WorkerId = workerId });
|
||||
services.AddOSSService("HuaweiCloud", "OSSProvider");
|
||||
}
|
||||
|
||||
public void Configure(IApplicationBuilder app, IWebHostEnvironment env)
|
||||
|
||||
Reference in New Issue
Block a user