Using the Folder method

The following uses the Folder method to publish the Web API to a folder first and then move the folder's content to the IIS site folder:

Step 1: On the development machine, open the PowerServer C# solution in SnapDevelop. Log in to SnapDevelop if required.

Click the Open C# Solution in SnapDevelop button () in the PowerBuilder toolbar to launch the PowerServer C# solution in SnapDevelop. Or go to the location where the PowerServer C# solution is generated; and double click PowerServer_[appname].sln to launch the solution in SnapDevelop.

At startup, the solution will install/update the dependencies. Wait until the Dependencies folder completes the install/update. (Make sure the machine can connect to the NuGet site: https://www.nuget.org in order to successfully install PowerServer NuGet packages).

Step 2: In the Solution Explorer, right click on the ServerAPIs project node, and select Publish.


Step 3: In the window that appears, select Folder, and click Next.


Step 4: Use the default location or specify a different location where the files will be published, and click Next.


Step 5: Click the Edit publish profile icon after the Release setting.


Step 6: Select the Self-Contained deployment mode and the appropriate target runtime, and then click Save.

  • A Self-Contained package will not only include the project itself and its dependencies, but also include the .NET Core runtime and libraries. Users can run it on a machine that has no .NET Core runtime installed.

  • A Framework-Dependent package will only include the project itself and its dependencies. Users have to install the .NET Core runtime in order to run the project.

Note: Do not select the "Produce single file" option underneath; it is unsupported by PowerServer.


Step 7: Click Publish.


Step 8: Make sure publishing was successful as shown in the figure below.

You can view the publish progress and result in the Output window.


Step 9: Click the target location in the publish wizard to open the folder that contains the published files.


You will see a bunch of files generated under the "publish" folder.


Step 10: Copy all files from the "publish" folder to the server.

Suppose the server is running IIS with IP address 172.16.100.83, port number 81, and physical path C:\inetpub\testsite_root; then you should copy all files from the "publish" folder to C:\inetpub\testsite_root, as shown below.

After that, the IIS process manager will automatically launch the Web APIs when requests are made to http://172.16.100.83:81.

Although you don't need to start the Web APIs manually, you can verify the Web APIs by following the instructions in the next section: Verifying the Web APIs.


But before you can run the installable cloud application, you might need to adjust the following settings first:

  • Specify the Web API URL (for example, https://172.16.100.83:81) in the .NET Server page of the PowerServer project painter and then build and deploy the project again. If you do not want to build and deploy the project again, you can also directly change the value of the Web API URL stored on the Web server using the command-line tool (CustomizeDeploy.dll). See this section for more details.

  • If you use the SQL Anywhere database or ASE database which supports only ODBC connection at this moment, you will also need to set up the corresponding ODBC data source in the server where Web APIs is published and running.