abp icon indicating copy to clipboard operation
abp copied to clipboard

Volo Docs does not support IIS subapps

Open alvahdean opened this issue 1 year ago • 0 comments

Is there an existing issue for this?

  • [X] I have searched the existing issues

Description

Running a Volo Docs app in an IIS subapp (e.g. http://mysite.com/DevDocs) renders incorrect links to documentation (missing the sub app path.

Reproduction Steps

  1. Checkout dev branch

  2. Build VoloDocs.Web sample app in /modules/docs/Volo.Docs.sln

  3. Update your launchSettings.json for IIS Express to simulate an IIS subapp. You can deploy to real IIS as a subapp but this behaves the same

    "iisSettings": {
        "windowsAuthentication": false,
        "anonymousAuthentication": true,
        "iisExpress": {
        "applicationUrl": "https://localhost:44333/DevDocs",
        "sslPort": 0
        }
    }
    
    
  4. Ensure at least two projects are defined in the database (per Volo Docs install docs)

  5. Run the app.

  • Click on a project and Follow basic document navigation (all links should be missing the /DevDocs subapp url part)
  • Login as admin and go to the /Administration/Projects page, list fails to populate b/c the API call is missing the /DevDocs

Expected behavior

Assuming app is running on https://localhost:44333/DevDocs

  1. All links on a project documentation page should work
  2. Administration pages should work

Actual behavior

1a. The Project name link doesn't work 1b. The "Return to Root" icon (<) doesn't work (missing /DevDocs path part) 1c. The documentation navigation links don't work (missing /DevDocs path part) 2. Volo Docs Adminstration pages throw errors due to API calls missing /DevDocs path part

Regression?

No, did not work in 8.2 but PR #20393 fixed the Index page links.

Known Workarounds

Manually adding /DevDocs to the rendered links returns the correct page content

Version

8.2 & dev

User Interface

MVC

Database Provider

EF Core (Default)

Tiered or separate authentication server

None (Default)

Operation System

Windows (Default)

Other information

I have a working patch for the public_app part of the library.

alvahdean avatar Aug 08 '24 02:08 alvahdean