-
Notifications
You must be signed in to change notification settings - Fork 5
WindowsServer2019
THIS PAGE IS OUTDATED AND WILL BE UPDATED SOON TO REFLECT THE INSTRUCTIONS FOR VERSION 8.x.y INSTRUCTIONS. PLEASE USE DOCKER INSTEAD.
This page describes the procedure for a CDP4-COMET Webservice for IIS initial installation how to install updates on Windows Server 2019.
- .NET Framework 4.7.2 needs to be installed on the server
- A PostgreSql version 12.x CDP4-COMET database server should be accessible from this server.
- Download the latest PostgreSql version 12.x release from the PostgreSql download website .
- Install PostgreSql version 12.x
- Make sure that all components that can be installed in the installation are installed.
- Don't forget the admin user password that you need to define during installation. We need it for later use.
- Leave the option
Default Locale
when asked for a locale to use for the database cluster.
- After PostgreSql installation, make sure that the PostgreSql database can be accessed from the server where the CDP4-COMET Webservice for IIS will be running.
- Download the PostgreSql initialization script and save it somewhere on disk (\cdp4server.sql).
- Run the PostgreSql initialization script as a PostgreSql admin user using psql, which is located in the
Program Files\PostgreSQL\12\bin
folder:psql -h localhost -U postgres -p 5432 -q -f <FileLocation>\cdp4server.sql
The CDP4-COMET-Webservice for IIS requires IIS to be installed with ASP.NET 4.7.2 or higher.
The server needs to be restarted during the installation process.
If Internet Information Services isn't already installed on the server, then we need to add it using the "Add roles and features" option in the Server Manager.
- Confirm using
Next
button
- Select
Role-based or feature-based installation
- Confirm using
Next
button
- Select the correct Server, or virtual hard disk.
- Confirm using
Next
button
- Select the option
Web Server (IIS)
- After you select this option a dialog pops up (see image below)
- Confirm installation of IIS Management Console by clicking
Add Features
At this point the Web Server (IIS)
option will be selected.
Depending on previous installations, the option can be expandable (Image 1 below), or not (Image 2 below).
Image 1
In case the option is expandable immediately, please select ASP.NET 4.7 (or higher) under Web Server => Application Development
together with ISAPI Extensions
and ISAPI FIlters
.
- Confirm using
Next
button
Image 2
In case the option is NOT expandable immediately then after the IIS installation is done, we need to execute Add roles and features
in the Server Manager a second time and select the option as shown in Image 1 (see above) to finish the installation.
- Confirm using
Next
button
- Select the option
ASP.NET 4.7
(or higher)- Confirm using
Next
button
- Confirm using
Next
button
- Select the option
Basic Authentication
underWeb Server => Security
- Confirm using
Next
button
- Confirm using the
Install
button
IIS will now be installed and when it is finished the server should be restarted. Depending on previous steps we might need to run the installation again (see image 1 and image 2 above).
Although the CDP4-COMET Webservice can be added to an existing IIS Website (root, and subfolder), for this installation manual we have chosen to create a new Website and install the CDP4-COMET Webservice in its root folder.
- Open IIS Manager
- Right click on the
Sites
node and chooseAdd Website
from the menu
- Choose a Site name
- Choose the Application pool (preferred way is to create a new Application pool for optimal execution isolation of the CDP4-COMET Webservice)
- Choose the physical path to the CDP4-COMET Webservices' location on disk.
- Set the binding data as preferred
The user that is defined in the Application Pool that was created for the web site should have correct access to the comet-webservice folder:
- Modify
- Read and execute
- List folder contents
- Write
For more information on IIS user access see Microsoft Documentation on Application Pool Identities
Download the latest COMET-Webservices-IIS-x.x.x.zip
file from CDP4-COMET Webservice releases
- Extract the files from the latest CDP4-COMET Webservice for IIS zipfile to the root folder of the website we defined in a previous step.
The end result should be that the root folder contains two .config
files and a Bin
folder
In the Bin folder you can find a file config.json.new
.
This file contains the CDP4-COMET Webservices' application settings.
It is however not the file that will be used at runtime.
For that to be the case we need to rename the file to config.json
.
The reason for this manual step is that we do not want to overwrite the config.json settings during updates. In every CDP4-COMET-Webservices for IIS zip file, a new version of the config.json.new
file can be found that can be used as a reference to update the config.json
file.
After renaming config.json.new
to config.json
we open the file, for example using notepad.
The only thing that needs to be changed is here is the Backtier section according to the CDP4-COMET (Postgres) database installation.
Don't forget to save the file.
Please do not change the web.config file. The file gets overwritten on every update.
Changes to parent (web server) config files are necessary for the CDP4-COMET Webservice for IIS to execute correctly.
To make these changes, please open the Configuration Editor (right panel) at the WebServer level
as indicated in the left panel in the above image.
On the WebServer level in IIS, certain config values are locked for changes in deeper hierarchycal configuration levels (Microsoft Documentation on IIS config file hierarchy).
We need to unlock the following sections:
- system.webServer.httpRedirect
- system.webServer.modules
- system.webServer.handlers
Unlocking can be done by selecting the section using the dropdown selector at the top of the Configuration Editor panel and selecting Unlock Section
from the Actions
(right) panel.
If the section is unlocked successfully, you will see the option Lock Section
instead of Unlock Section
in the Actions
panel.
Don't forget to Apply the changes.
If you browse to the website, the CDP4-COMET Webservices' Welcome page should show.
Updating the CDP4-COMET Webservice for IIS works pretty much the same as installing it for the first time.
Download the latest COMET-Webservices-IIS-x.x.x.zip
file from CDP4-COMET Webservice releases
- Extract the files from the latest CDP4-COMET Webservice for IIS zipfile to the root folder of the IIS Website.
The end result should be that the root folder contains two .config
files and a Bin
folder.
After the update, in the Bin folder you can find a file config.json.new
.
This file contains the latest version of the CDP4-COMET Webservices' application settings.
It is however not the file that will be used at runtime.
The config.json.new
can be used as a reference to update the existing config.json
file.
copyright @ Starion Group S.A.