Compare commits
1 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| eb577f6e89 |
16
.github/workflows/build.yml
vendored
16
.github/workflows/build.yml
vendored
@@ -124,6 +124,14 @@ jobs:
|
||||
"Microsoft.AspNetCore" = "Warning"
|
||||
}
|
||||
}
|
||||
Seq = @{
|
||||
ServerUrl = "https://log.azaaxin.com"
|
||||
ApiKey = "KEY"
|
||||
MinimumLevel = "Trace"
|
||||
LevelOverride = @{
|
||||
Microsoft: "Warning"
|
||||
}
|
||||
}
|
||||
ApiConfiguration = @{
|
||||
EspConfiguration = @{
|
||||
InformationBoardImageUrl = "http://server_ip:port/home/default.jpg"
|
||||
@@ -178,6 +186,14 @@ jobs:
|
||||
"Microsoft.AspNetCore" = "Warning"
|
||||
}
|
||||
}
|
||||
Seq = @{
|
||||
ServerUrl = ${{ vars.SEQ_URL }}
|
||||
ApiKey = ${{ secrets.seq_api_key }}
|
||||
MinimumLevel = "Trace"
|
||||
LevelOverride = @{
|
||||
Microsoft: "Warning"
|
||||
}
|
||||
}
|
||||
ApiConfiguration = @{
|
||||
EspConfiguration = @{
|
||||
InformationBoardImageUrl = "${{ vars.ESP_IMAGE_URL }}"
|
||||
|
||||
@@ -17,6 +17,7 @@
|
||||
<PackageReference Include="RazorLight" Version="2.3.1" />
|
||||
<PackageReference Include="Refit.HttpClientFactory" Version="8.0.0" />
|
||||
<PackageReference Include="Scalar.AspNetCore" Version="2.5.6" />
|
||||
<PackageReference Include="Seq.Extensions.Logging" Version="8.0.0" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
@@ -30,5 +31,8 @@
|
||||
<Content Include="wwwroot\index.cshtml">
|
||||
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
|
||||
</Content>
|
||||
<Content Include="..\.github\workflows\build.yml">
|
||||
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
|
||||
</Content>
|
||||
</ItemGroup>
|
||||
</Project>
|
||||
|
||||
@@ -1,8 +1,12 @@
|
||||
using HomeApi.Registration;
|
||||
using Scalar.AspNetCore;
|
||||
using Serilog;
|
||||
|
||||
var builder = WebApplication.CreateBuilder(args);
|
||||
|
||||
builder.Services.AddLogging(loggingBuilder =>
|
||||
{
|
||||
loggingBuilder.AddSeq(builder.Configuration.GetSection("Seq"));
|
||||
});
|
||||
builder.Services.AddHttpClient();
|
||||
builder.Services.AddMediatR(cfg => cfg.RegisterServicesFromAssemblyContaining<Program>());
|
||||
builder.Services.AddControllers();
|
||||
@@ -22,4 +26,4 @@ app.UseAuthorization();
|
||||
|
||||
app.MapControllers();
|
||||
|
||||
app.Run();
|
||||
app.Run();
|
||||
|
||||
@@ -12,6 +12,14 @@
|
||||
"Microsoft.AspNetCore": "Warning"
|
||||
}
|
||||
},
|
||||
"Seq": {
|
||||
"ServerUrl": "https://log.azaaxin.com",
|
||||
"ApiKey": "KEY",
|
||||
"MinimumLevel": "Trace",
|
||||
"LevelOverride": {
|
||||
"Microsoft": "Warning"
|
||||
}
|
||||
},
|
||||
"ApiConfiguration": {
|
||||
"EspConfiguration": {
|
||||
"InformationBoardImageUrl": "http://192.168.101.178:5000/home/default.jpg",
|
||||
|
||||
@@ -12,6 +12,14 @@
|
||||
"Microsoft.AspNetCore": "Warning"
|
||||
}
|
||||
},
|
||||
"Seq": {
|
||||
"ServerUrl": "https://log.azaaxin.com",
|
||||
"ApiKey": "KEY",
|
||||
"MinimumLevel": "Trace",
|
||||
"LevelOverride": {
|
||||
"Microsoft": "Warning"
|
||||
}
|
||||
},
|
||||
"ApiConfiguration": {
|
||||
"EspConfiguration": {
|
||||
"InformationBoardImageUrl": "http://192.168.101.178:5000/home/default.jpg",
|
||||
|
||||
Reference in New Issue
Block a user