Avatar of joachim58
joachim58
 asked on

MVC5 App runs on development machine but gives HTTP 404.0 or 403.14 when deployed to http://w.x.y.z/Default Web Site/Application

The MVS application CCCFE07 starts without problems on the development machine
It is deployed to our demo webserver using the Framework 4.5 Web-Deployment feature
server: http://80.90.100.110
site name: Default Web Site/CCCFE07
destination URL: http://80.90.100.110
Validate Connection is ok

RouteConfig is
namespace CCCFE07 {
    public class RouteConfig {
        public static void RegisterRoutes( RouteCollection routes ) {
            routes.IgnoreRoute( "{resource}.axd/{*pathInfo}" );

            routes.MapRoute(
                name: "Default",
                url: "{controller}/{action}/{id}",
                defaults: new { controller = "Home", action = "Index", id = UrlParameter.Optional }
            );
        }
    }
}
CCCFE07\Views\Home\Index.cshtml  exists

The Web Deploy feature installs the app on the server to Default Web Site/CCCFE07 and maps Default Web Site/CCCFE07 to the physical path c:\inetpub\wwwroot\CCCFE07 where we can see the subdirectories bin, Content, fonts, Scripts, Views

Trying to start the app on the server with
- localhost/cccfe07 gives error 403.14 Forbidden
- localhost/cccfe07/Home gives error 404.0 not found which seems reasonable since physical path C:\inetpub\wwwroot\CCCFE07\Home\ does not exist
- localhost/cccfe07/Views gives error: Method not found: '!!0[] System.Array.Empty
- localhost/cccfe07/Views/Home gives same error

"Enable Directory Browsing" is probably no option, since the configured start document shall be started
A default document is defined in RouteConfig (see above)

What must be done so that the http://localhost/CCCFE07 app can be startet on the Web Server?

Thanks for your help.

Joachim
ASP.NETWeb DevelopmentMicrosoft IIS Web ServerWeb ApplicationsWeb Servers

Avatar of undefined
Last Comment
joachim58

8/22/2022 - Mon
ASKER CERTIFIED SOLUTION
Dan McFadden

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
joachim58

ASKER
Dan,
thank you very much for your comment. Using the first link you listed the problem could be solved.
regards
Joachim
Dan McFadden

Glad to have helped.

Dan
joachim58

ASKER
Problem solved. Thank you.
All of life is about relationships, and EE has made a viirtual community a real community. It lifts everyone's boat
William Peck