Serving UI Directories

Prev Next

UI Directories Property

For all services with a user interface (UI) that serve static files, the uiDirectories property is now required at the root level of the pronghorn.json file. The property is a list of top level directory names, in which only the files within those directories are served by Itential Platform.

The default methodology to serve static files is by uiDirectories. If no uiDirectories property exists, all static files are served; however, once the new property takes effect, only the files specified within uiDirectories are statically served. No other files outside uiDirectories are served.

Example

In the following example, all files within the build, img, and icon directories are served by Itential Platform. No other files will be served by Itential Platform.

{
    "id": "@itential/app-test",
    "uiDirectories": ["build", "img", "icon"],
    "encrypted": true,
    "src": "cog.bing",
    "type": "Application",
    "export": "test",
    "title": "test",
    "summary": "Test",
    "pdb": true,
    "roles": ["admin", "engineering", "support", "apiread", "apiwrite"],
    "methods": [],
    "views": []
}

Further Reading

Please review the deprecation product notice for Serving Static Files.