Unable to deploy the app from CA-PM GitHub Repository
search cancel

Unable to deploy the app from CA-PM GitHub Repository

book

Article ID: 280757

calendar_today

Updated On: 12-11-2024

Products

Network Observability CA Performance Management

Issue/Introduction

We are attempting to deploy the Device Polling Health app from the CA-PM GitHub Repository (https://github.com/CA-PM) to monitor device polling health within DX NetOps.

However, during the process of adding the app, the following error message is encountered:

App Not Deployed

Apps that contain invalid files are not allowed.

Screenshot:



What files and/or extensions are allowed?

Environment

DX NetOps Performance Management All Releases

Cause

The error you're encountering stems from a security measure implemented within the product.

Specifically, certain file types are blocked to enhance the overall security of the system. Among these blocked file types are JSP (JavaServer Pages) and XSP.

These file types are restricted to prevent potential security vulnerabilities and unauthorized access to the system. While this measure helps safeguard the product and its data, it may occasionally result in errors when attempting to deploy certain applications or components that rely on these file types.

It's essential to understand the reasoning behind these restrictions and take appropriate measures to work within the confines of the system's security protocols.

Also check for hidden files and directories which may not be displayed by a zip application.

Resolution

To address this issue and allow additional file types for deployment, follow these detailed steps:

  1. Navigate to Configuration File:

    • Open the configuration file located at: PC/webapps/pc/WEB-INF/cfg/portal.console.properties
  2. Add the Whitelist Property:

    • Since the property appDeploymentExtensionWhitelist does not exist by default, you need to add it manually to the configuration file.
    • Open the configuration file using a text editor.
    • Scroll to the end of the file or to an appropriate location.
    • Add the following line:
       
      appDeploymentExtensionWhitelist=jpg,png,gif,svg,css,js,html,xhtml,properties,md,txt,xml,json,donotdelete,gitignore,jshintrc,jsp,zip

    This line specifies the whitelist of allowed file extensions for application deployment.

    NOTE - Review the App Package and edit the line above with all file extensions in the package.
  3. Ensure Correct Syntax:

    • Ensure that the line is added exactly as shown, with each file extension separated by commas.
    • Do not include any spaces between file extensions.
  4. Save and Close the Configuration File:

    • Save the changes made to the configuration file.
    • Close the text editor.
  5. Restart DX NetOps Portal Services:

    • After making the changes, restart the DX NetOps Portal Services to apply the new configuration settings.

Important Note When Adding New Extensions:

When adding new extensions, it's crucial to include both the existing list and the new extensions. This ensures that the server remains secure while allowing the necessary file types for app deployment.

Note for Security:

Be cautious when adding file extensions to the whitelist. Some extensions may introduce security vulnerabilities or make the application less secure. Only add extensions that are necessary for the application's functionality.

By following these detailed steps, you should be able to deploy the app successfully in DX NetOps.

 

Additional Information

Tip: When packaging use a zip allowlist to avoid packaging any files which are not allowed.

Example:

zip -r appname.zip appdirectory -i "*.jpg" "*.png" "*.gif" "*.svg" "*.css" "*.js" "*.html" "*.xhtml" "*.properties" "*.md" "*.txt" "*.xml" "*.json" "*.donotdelete" "*.gitignore" "*.jshintrc" "*.jsp" "*.zip"

Adjust if you add extensions to the default list.