Tried to publish an Angular ASP.NET Core application in IIS but it is not working already tried this solution but cannot solve it Deploying Angular 6 ASP.NET Core application
Already tried this one.
public void ConfigureServices(IServiceCollection services)
{ services.AddMvc().SetCompatibilityVersion(CompatibilityVersion.Version_2_1);
....
// In production, the Angular files will be served from this directory
services.AddSpaStaticFiles(configuration =>
{
configuration.RootPath = "ClientApp/dist/ClientApp";//change here
});
...
}
Am I missing something?

configuration.RootPathpath is correct? Does theClientApp/dist/ClientAppdirectory exist in your project'swwwrootfolder or somewhere else? What happens if you specify an absolute path instead?