I want to add rules to a .net core project. In a .net normal project I have the facility to edit directly the web.config file
Actually I need to achieve this, in a .net core project
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<location path="." inheritInChildApplications="false">
<system.webServer>
<handlers>
<add name="aspNetCore" path="*" verb="*" modules="AspNetCoreModuleV2" resourceType="Unspecified" />
</handlers>
<aspNetCore processPath="dotnet" arguments=".\RazorWeb.dll" stdoutLogEnabled="false" stdoutLogFile=".\logs\stdout" hostingModel="OutOfProcess" />
</system.webServer>
</location>
<system.webServer>
<rewrite>
<!---START:ADD THIS RULES-->
<rules>
<rule name="httpTohttps" stopProcessing="true">
<match url="^(.*)$" />
<conditions>
<add input="{HTTPS}" pattern="off" ignoreCase="true" />
</conditions>
<action type="Redirect" url="https://{HTTP_HOST}/{R:1}" redirectType="Permanent" />
</rule>
</rules>
<!---END:ADD THIS RULES-->
</rewrite>
</system.webServer>
</configuration>
Well since I Introduced in .net core I noticed the template projects doesn't came with this .config file, however the templates use the .csproj file and .json files to add configurations etc...
The main idea is how can achieve this in a .net core project, I was seaching in diferents sites, the docs of microsoft are not totally clear for my in this aspect, the nearest thing that I found was this
https://roslyn-analyzers.readthedocs.io/en/latest/config-analyzer.html But doesn't work for me