Azure App Service Linux/Tomcat Web App opens default parking page instead of my app

Carlescu, Dragos 0 Reputation points
2024-03-19T17:41:28.28+00:00

I have an Azure App Service web app deployed on Linux/Java 17/Tomcat 10. I'm doing a zip deploy of my app and I can see the files unzipped and deployed under the folder /home/site/wwwroot. But when I try to navigate to the app, it still tries to open the default parking page, it doesn't uses the app deployed in the wwwroot folder.

In the logs, I can see that it's deploying the landing app ("Using parking page app with SITEROOT=/usr/local/appservice/parkingpage") and when I check the JAVA_OPTS variable in the SSH console, I see that it's pointing to that folder (" -Dsite.root=/usr/local/appservice/parkingpage ")

How do I get the app to use the /home/site/wwwroot and stop using the landing page? I tried to modify pass the JAVA_OPTS as an app setting and set the -Dsite.root=/home/site/wwwroot manually, but it didn't take the value.

Azure App Service
Azure App Service
Azure App Service is a service used to create and deploy scalable, mission-critical web apps.
8,934 questions
{count} votes

1 answer

Sort by: Most helpful
  1. SnehaAgrawal-MSFT 22,706 Reputation points Moderator
    2024-03-20T16:48:13.3666667+00:00

    @Carlescu, Dragos Thanks for reaching here!

    If Parking page is showing this means there is no war file existing on the file system, or we App Service can’t find it to run. Additionally, there is a possibly a war or war-folder context exists, but the method being used to deploy did not let the platform appropriately unpack to /usr/local/tomcat/webapps/[context].

    For deployments using .war files, validate that:

    • If /home/site/wwwroot or /home/site/wwwroot/webapps is being used. Check the war is actually under one of these two paths. If both of the above file system locations exist, then only one (1) of these locations should be used and the other deleted.
    • Check if the same context name is appearing under /usr/local/tomcat/webapps/[context] within the container.
    • Validate that if using /home/site/wwwwroot/[war].war that /home/site/wwwroot/webapps/ROOT exists with appropriate expanded contents under ROOT Validate that if using /home/site/wwwwroot/[war].war that /home/site/wwwroot/webapps/[context] exists with appropriate expanded contents under [context]

    You may refer to this detailed blog for details-

    Tomcat deployments on App Service - War file location, behavior and troubleshooting

    Please let us know if further query or issue remains.

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.