I am trying to host a nextjs website on iis here is my set up .
- Website with web.config hosted under default site
Contents of web.config which causes nextjs site . On access of http://localhost/AppWithNode1/SimpleErrorView it should redirect to the nextjs site.

On navigate to the http://localhost/AppWithNode1/SimpleErrorView it shows the nextjs 404 error page
the console shows 404 for the js and css assets too.
- I have tried with adding a basepath to the nextjs.config.mjs and a assetPrefix still get the same error . Im not sure what else is missing to get this to work ? .Any help would be appreciated Thanks .

Edit:
Output from the port hosted via httpplatformhandler





