-2

I found a way to deploy node app in iis route with iisnode and urlrewrite. it worked very well.could any one help to this problem.

1

1 Answer 1

0

try to use the ng build command with href and use value of the virtual directory name.

below URL rewrite rule:

<rule name="StaticContent" patternSyntax="Wildcard">
                <action type="Rewrite" url="public/{R:0}" logRewrittenUrl="true"/>
                <conditions>
                    <add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true"/>
                </conditions>
                <match url="*.*"/>
            </rule>

          
            <rule name="DynamicContent">
                <conditions>
                    <add input="{REQUEST_FILENAME}" matchType="IsFile" negate="True"/>
                </conditions>
                <action type="Rewrite" url="server.js"/>
            </rule>
            <rule name="SocketIO" patternSyntax="ECMAScript">
                <match url="socket.io.+"/>
                <action type="Rewrite" url="server.js"/>
            </rule>

make sure iisnode module is installed.

IIS, Node.js, and Web Application with IISNode not configured right with Virtual Directory

Running nodejs/MEAN app on IIS virtual directory setup

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.