- Print
- DarkLight
- PDF
Installation
Upon deployment, the following guide may be used; notice that the steps outlined below may change, and the screenshots used may differ depending on the Operating System the API is being deployed on.
In case you have version 7.3 or earlier version of the API please refer to this installation page. In case you are installing a newer version, then this page is for you.
DBMS
The Safran API requires a database connection. The Safran API includes both Oracle and Microsoft SQL Server packages. Meaning that the neccessary client drivers are part of the Safran API. This ensures that the Safran API can connect to Oracle and Microsoft SQL Server without requiring any additional client installations on your server.
Oracle
The Safran API includes the fully managed Oracle Data Provider for .NET (ODP.NET) Core: from Oracle.
Microsoft SQL Server
The Safran API includes the fully managed .NET Data Provider for SQL Server driver from Microsoft.
Prerequisite
Before installing the Safran Software Solution, a few elements must be present.
Window Server
- Ensure your server is running Windows Server 2012 R2 or similar.
- Make sure that your server has the latest Windows updates.
Internet Information Services (IIS)
Within the Windows "Control Panel" under "Programs and Features" and "Turn Windows features on or off," the following needs to be present:
Enable Internet Information Servies (IIS):
- Expand the Internet Infration Service node.
- Check the box for Web Management Tools:
- IIS Management Console: This is essential for managing your IIS server.
- Check the box for World Wide Web Services:
- Application Development Features: Ensure the following are checked:
- .Net Extensibility 4.8
- ASP.NET 4.8
- ISAPI Extentions
- ISAPI Filters
- Common HTTP Features: Ensure the following are checked:
- Default Document
- Directory Browsing
- HTTP Errors
- Static Content
- Health and Diagnostics: Ensure the following are checked:
- HTTP Logging
- Request Monitor
- Performance Features: Endsure the following are checked:
- Static Content Compression
- Security: Ensure the following are checked:
- Request Filtering
- Windows Authentication
- In case you are going to use the Kerberos Authentication
- In case you are going to use the Kerberos Authentication
- Application Development Features: Ensure the following are checked:
The server should now host a C:\inetpub folder with the following sub-folders:
- custerr
- history
- logs
- temp
- wwwroot
Install the .NET Core Hosting Bundle:
- This is not part of the Windows features but is essential for running .NET Core applications on IIS, such as the Safran Project Integration API and Safran Project ILAP Gateway API.
- Download and install it from the Microsoft website. It might be found here: Microsoft .net core hosting bundle
- Follow the installation instructions from Microsoft.
Setup the Safran Solution
This document will guide the reader through the setup of Safran Solution as Safran Project ILAP Gateway API and Safran Project Integration API. Both will be referred to as "Safran Solution". This document will also describe how to verify the installation and setup.
Install the Safran Software solution
- Collect the Safran Solution, which is most likely delivered as a compressed zip file.
- On the Windows server where the Safran Solution is to be installed, open a File Explorer window.
- Navigate to the folder C:\inetpub\wwwroot
- Create a new subfolder named "SafranILAPGateway" or "SafranIntegrationAPI", depending on which system to install. Should you prefer another name, use such instead.
- Extract the delivered compressed zip file into the newly created subfolder.
- In case the zip file is blocked you need to unblock the file prior extracting.
- Your subfolder should look something like this:
Setup Internet Information Services (IIS) Manager
- Open the START menu on the Window on the server where the Safran Solution will be installed.
- Type "iis" while the start menu is open.
- Internet Information Service (IIS) Manager is opened.
- On the left-hand side, locate the "Sites" folder and select to expand it. There may or may not be sites already added to the IIS.
- Right Mouse click the "Sites" item and select "Add Website…" from the popup menu.
- The "Add Website" dialog opens
- The following input fields need to be configured:
- Port
- Defined the port where the Safran System is accessible. In this example, I have selected "83."
- IP address
- This is typically left as is
- Type
- Select HTTP or HTTPS; the recommendation is to use HTTPS; in this sample, I will choose HTTP. See IIS documentation for details on HTTPS.
- Host name
- This is typically left blank.
- Site name
- This is the application's name, and as a good practice, the name should also include the port number.
- In this sample, I added the Safran Solution: Safran ILAP Gateway, with port 83; therefore, I chose "SafranILAPGateway 83" as the name."
- Application pool
- This is typically left as is
- Physical path
- This will point to the subfolder where the compressed zip files were extracted and the Safran Solution's placement.
- "C:\inetpub\wwwroot\SafranILAPGateway"
- Port
Within your IIS, you should be able to browse to the WebSite. When your prowser opens add "/v1/test/ to the URL. It could read something as http://localhost:83/v1/test. The result you should get is "Check was successful."
Firewall
Make sure that the server hosting the Safran solution has an open port on its firewall, which corresponds to the port defined in the IIS setup.
Using the same checkpoint as above you should be able to access the "test" from another computer, and instead of "localhost" you need to use the "IP address" of the server.
Make sure that the API server can reach the Safran License Server as per License
Database connection
A database connection is a crucial component that allows Safran API client software to communicate with database server software. This connection is necessary to send commands and receive responses, typically in the form of a result set.
Connection strings
A database connection string is a string of text that specifies information about a data source and how to connect to it. It includes details such as the database server’s address, the database name, user credentials, and other configuration settings. Connection strings are essential for the Safran API to establish a connection to your database.
For the Safran API the connection string is located in a file named "appsettings.json".
Sample Microsoft connection string
Server=myServerAddress;Database=myDataBase;User Id=myUsername;Password=myPassword;
- Server: The address of the database server. This can be an IP address, a server name, or a network name.
- Database: The name of the database you want to connect to.
- User Id: The username used to authenticate with the database.
- Password: The password associated with the user ID.
"default": "Server=SafranMSSServer;Database=SafranDatabase;User Id=SAFRANSA;Password=safran;",
Sample Oracle TNS connection string
Data Source=myServerAddress:myPort/myDatabase;User Id=myUsername;Password=myPassword;
- myServerAddress: The address of the database server. This can be an IP address, a server name, or a network name.
- MyPort: This is the port of the IP address used in the myServerAddress.
- myDatabase: The name of the database you want to connect to.
- User Id: The username used to authenticate with the database.
- Password: The password associated with the user ID.
"default": "Data Source=SafranOraServer:1521/SafranDatabase;User Id=SAFRANSA;Password=safran;Max Pool Size=200;",
Sample Oracle TNSless connection string
See the Glossary for more explanation of TNS-Less connection.
Data Source=(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=myServerAddress)(PORT=myPort))(CONNECT_DATA=(SERVICE_NAME=myDatabase)));User Id=SAFRANSA;Password=safran;
- myServerAddress: The address of the database server. This can be an IP address, a server name, or a network name.
- MyPort: This is the port of the IP address used in the myServerAddress.
- myDatabase: The name of the database you want to connect to.
- User Id: The username used to authenticate with the database.
- Password: The password associated with the user ID.
"default": "Data Source=(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=127.0.0.1)(PORT=1521))(CONNECT_DATA=(SERVICE_NAME=SafranDatabase)));User Id=SAFRANSA;Password=safran;"
appsettings.json
Within the subfolder where the Safran Solution was installed. There is a file called "appsettings.json". We need to adjust this to connect to our database.
"ConnectionStrings": {
"default": "Data Source=SafranOra:1521/SafranDatabase;User Id=SAFRANSA;Password=safran;Max Pool Size=200;",
"default_mss": "Server=SafranDatabaseServer;Database=SafranDatabase;User Id=SAFRANSA;Password=safran;",
"default_ora": "Data Source=(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=127.0.0.1)(PORT=1521))(CONNECT_DATA=(SERVICE_NAME=SafranDatabase)));User Id=SAFRANSA;Password=safran;"
},
Within your IIS, you should be able to browse to the WebSite. When your prowser opens add "/v1/version/ to the URL. It could read something as http://localhost:83/v1/version. The result you should get is a value larger than 100 in the databaseLevel."
Setup tests
These steps guide the reader through initial tests to verify the installation and setup are working.
Within the IIS, select the newly added Site.
Ensure the site is running, indicated with a grey "Start" option on the right-hand side.
Within the IIS, select the added Site and choose "Browse" from the options on the right-hand side.
Browser site test
- An empty Internet Explorer window should open. It should also show the Safran Software Solutions logo.
- Within the address, add "index.html" and press [enter]
- The page should load and present content
Safran Solution accessibility test
- In the address bar, replace "index.html" with "v1/test" and enter.
- With "Safran ILAP Gateway", we will correctly get "400 Bad Request"
- With another solution, we will get a "200 Success" replay.
- If you get messages such as "Invalid license, " your Configuration File file may not be as it should be. Please see below for a sample file.
- In the address bar, replace "v1/test" with "v1/version?type=json" and enter.
- Regardless of Safran Solution, the user should receive the solution version details.
Safran Solution client test
This test will be conducted on a computer different from the server where the Safran solution was installed. This is to ensure firewalls are open and the Safran Solution is accessible outside the server environment.
- Collect the address of the IIS server, either IP or the server's name.
- Start an internet browser software, and within the address field, enter the server's address and add "index.html", press enter.
- The index page should present it selves.
- Within the index page, scroll to the bottom and press the check version and database connectivity. As a result, the user should receive the Safran Solutions version details.
- Access these URLs from the client:
- "/v1/project_previews/"
- "/v1/project_previews/?owner=safran" – where safran is a real Safran user owning projects.
Additional database test
Oracle
Access to database objects
- The system is accessing Oracle system tables, views and synonyms, such as 'USER_TAB_COLUMNS'. These are public by default configuration and must be accessible for the database user defined in the Connection Strings in the Configuration File file.
- Perform accessibility test by running this SQL towards the Safran database connected as the user-defined as described above.
- The SQL command below should return records as a result.
- The system is also accessing Oracle system table, views and synonym: 'DBA_USERS',
SELECT COLUMN_NAME, DATA_TYPE FROM USER_TAB_COLUMNS WHERE upper (table_name) = 'NETWORKS';
Microsoft SQL
Access to database objects
The system is accessing Microsoft system tables and views, such as 'information_schema.columns'. These are public by default configuration and must be accessible for the database user defined in the Connection Strings in the Configuration File file.
- Perform accessibility test by running this SQL towards the Safran database connected as the user-defined as described above.
- The SQL command below should return records as a result.
SELECT column_name, data_type FROM information_schema.columns WHERE upper (table_name) = 'NETWORKS';
Make sure that the above SQL, per your DBMS, can be ran for the user specified in the connection strings.
Additional configuration
This concludes the installation and configuration of the Safran Solution. See chapter Application Settings for details about the appsettings.json. It is recommended to apply security and additional configuration. See those chapters for that information.
appsettings.json file
See Configuration File for a sample content of the file.