Customize the deployed app using commands

When the application is deployed (from the PowerBuilder IDE) or installed (from the packaged executable installer or zipped file) to the Web server, the app files and config files are generated with hash codes, to prevent files changed illegally from running. Therefore, you cannot directly change the deployed settings/files on the Web server, instead you will have to make changes in the project painter and then deploy the application again, or modify the settings/files using commands (the CustomizeDeploy.dll tool).

The CustomizeDeploy.dll tool allows you to:

  • Change the External Files -- The "External Files" refers to the packages, folders, and files (such as INI files, DLL/OCX etc.) that are deployed from the External Files tab of the PowerServer project painter.

  • Change the Web API URL -- The Web API URL is stored on the Web server, so that the client knows where to call the PowerServer Web APIs at runtime. You may want to change the Web API URL value in the Web server, if you want the client to call the PowerServer Web APIs running on a different URL.

  • Encrypt a password -- You can encrypt the database login password used in the PowerServer project painter > Database Configuration, or in the PowerServer C# solution > ServerAPIs project > AppConfig > Applications.json file. You can use the encrypted string instead of the plain-text string to protect sensitive information.

You can find the CustomizeDeploy.dll tool in the "1.01" sub-folder of the application folder after the application is deployed or installed to the Web server (either from the PowerBuilder IDE or from the packaged executable installer or zipped file).

Important

Prerequisites

To execute the CustomizeDeploy.dll file using the dotnet command, you will need to install the ASP.NET Core Runtime 3.1 or later.

To run CustomizeDeploy.dll in Windows Web server:

  1. Install the ASP.NET Core Runtime 3.1 or later.

  2. Open the command prompt. (You'd better run the command prompt using an administrator by right-clicking it and then selecting "Run as administrator").

  3. Navigate to the Web server root folder > [application] folder > "1.01" (for example, C:\inetpub\wwwroot\pssales\1.01).

  4. Execute the CustomizeDeploy.dll file using the dotnet command.

To run CustomizeDeploy.dll in Linux Web server:

  1. Install the ASP.NET Core Runtime 3.1 or later.

    dnf install aspnetcore-runtime-5.0
  2. Go to the Web server root folder > [application] folder > "1.01" (for example, /var/www/html/pssales/1.01, or /usr/share/nginx/html/pssales/1.01).

  3. Right click the blank area within the folder and then select Open in Terminal.

  4. Execute the CustomizeDeploy.dll file using the dotnet command. Notice that the command and file name are all case-sensitive in the Linux OS.

    For example,

    dotnet CustomizeDeploy.dll -url=http://172.16.100.71:5009