Skip to content

Commit

Permalink
Add home controller with redirection
Browse files Browse the repository at this point in the history
  • Loading branch information
Boris Ahrens committed May 21, 2024
1 parent 594ebb3 commit f582beb
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 4 deletions.
17 changes: 17 additions & 0 deletions src/MalwareSampleExchange.Console/Controllers/HomeController.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
using Microsoft.AspNetCore.Authorization;

namespace MalwareSampleExchange.Console.Controllers;
using Microsoft.AspNetCore.Mvc;

[ApiController]
[Route("")]
[ApiExplorerSettings(IgnoreApi = true)]
public class HomeController : ControllerBase
{
[AllowAnonymous]
[HttpGet]
public IActionResult Get()
{
return Redirect("~/swagger/index.html");
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,4 @@
<ItemGroup>
<Folder Include="Properties\" />
</ItemGroup>
<ItemGroup>
<_ContentIncludedByDefault Remove="wwwroot\index.html" />
<_ContentIncludedByDefault Remove="wwwroot\web.config" />
</ItemGroup>
</Project>

0 comments on commit f582beb

Please sign in to comment.