mirror of
https://github.com/SpecterOps/Nemesis
synced 2026-06-08 12:36:42 +00:00
6525ce7140
Replace Minio backend storage with SeaweedFS (as Minio has been deprecated).
33 lines
921 B
C#
33 lines
921 B
C#
using Dapr.Client;
|
|
using ILSpyDecompilerService;
|
|
using ILSpyDecompilerService.Services;
|
|
using Microsoft.AspNetCore.Builder;
|
|
using Microsoft.AspNetCore.Http;
|
|
using Microsoft.Extensions.DependencyInjection;
|
|
using Microsoft.AspNetCore.Mvc;
|
|
using System;
|
|
|
|
var builder = WebApplication.CreateBuilder(args);
|
|
|
|
// Add services to the container
|
|
builder.Services.AddControllers().AddDapr();
|
|
|
|
builder.Services.AddControllers().AddNewtonsoftJson();
|
|
|
|
// Add our custom services
|
|
builder.Services.AddSingleton<S3StorageService>();
|
|
builder.Services.AddSingleton<DecompilerEngine>();
|
|
builder.Services.AddSingleton<AssemblyAnalysisService>();
|
|
|
|
var app = builder.Build();
|
|
|
|
// Configure the HTTP request pipeline
|
|
app.UseRouting();
|
|
app.UseCloudEvents();
|
|
app.MapControllers();
|
|
app.MapSubscribeHandler();
|
|
|
|
// Add health check endpoint
|
|
app.MapGet("/health", () => Results.Ok(new { status = "healthy", timestamp = DateTime.UtcNow }));
|
|
|
|
app.Run(); |