Set up IMPACT Service on Azure

Last modified by Per Dagbjer on 2025/03/24 16:55

This is a brief instruction for setting up the IMPACT WebAPI on Microsoft Azure Cloud Computing Services.

Please note that screenshots might differ slightly from the current Azure Portal. If in any doubt, please contact the IMPACT Support Team.

Set up a Resource Group

Azure Resources Groups are logical collections of virtual machines, storage accounts, virtual networks, web apps, databases, and/or database servers. Typically, users will group related resources for an application, divided into groups for production and non-production — but you can subdivide further as needed.

IMPACTSRequirements for the Resource Group are: 

  • The IMPACT WebAPI must be able to communicate with the IMPACT database.

For a list of Azure regions, please refer to https://azure.microsoft.com/en-us/global-infrastructure/locations/

Choose a location near to your operations.

1.png

Allow Access Through The Firewall

To be able to access your resource group, you need to open up the firewall on Azure for your specific IP address.

2.png

SQL Server

SQL in a Local Environment

If you currently don’t run IMPACT or if you want to test IMPACT on Azure with a clean database, you will first need an IMPACT database running in your local environment “on-premises”.

After having finished the installation procedure, you will have a clean database that can be migrated to Azure.

Set Up an SQL Server on Azure

The SQL Server on Azure should be tied to the resource group of your choice. Choose a location close to your operation.

5.png

Set Up an SQL Database on Azure

Create a blank database. Configure the pricing tier to match your performance needs. This database will be the target database during migration from the local server.

A Note about Collation Settings
A collation is a configuration setting that determines how the database engine should treat character data. Make sure that you select the correct collation because changing it afterward will include exporting the entire database and recreating it. Follow this link to read more about collation settings.

6.png

Migrate a Local SQL Database to Azure

Azure SQL Servers allows Azure SQL Databases. They differ from the ordinary SQL databases and therefore you cannot just simply connect to the server and restore a backup without having it migrated first.

Migrations can be performed by using Microsoft SQL Management Studio.

Right-click on the IMPACT database you want to migrate, choose Tasks and Deploy to Azure SQL Database and follow the guide.

7.png

Backup and Maintenance

Setting up backup and maintenance plans is based on individual usage of the service and it is not possible to give specific recommendations.

If the application is not used extensively, then a weekly or daily backup could suffice but if the application and the business rely heavily on the application, then a backup with transaction logs might be necessary for facilitate a restore to a specific point in time.

Web services

Requirements

The Azure Web App must be 64 bit and run on .NET 8 or higher. The minimum hardware requirement is 4 cores and 8 GB of RAM. The recommendation is 8 cores and 32 GB of RAM. Please see StruSoft Installer for further details.

Network and Security

IMPACT by norm uses webapi.company.com but this could vary from case to case. The WebAPI have no specific requirements with regards to DNS.

We recommend using HTTPS to safeguard from man-in-the-middle attacks.

If the Database and the Web Apps are placed in different resource groups, then it is important that the Web Apps are allowed to communicate with the database server at SQL-port 1433. 

Set Up a New Web App

8.png

Verify .NET Framework Version

1742570128470-256.png

Verify that the .NET Framework version is 8.0 and that the platform is 64-bit.

Edit The Parameters File

You can add the variables one by one or paste them all in with advanced edit.

Example:

1742830202050-910.png

Update all fields marked with XXX to the correct settings.

{

 "name": "Imp_ApiKeys",

 "value": "xxx",

 "slotSetting": false

 },
  {

    "name": "Imp_ConnectionString",

    "value": "Server=tcp:precast-001.database.windows.net,1433;Initial Catalog=xxx;Persist Security Info=False;User ID=xxx;Password=xxx;MultipleActiveResultSets=True;Encrypt=True;TrustServerCertificate=False;Connection Timeout=30;",

    "slotSetting": false

  },

 {

 "name": "Imp_EnableDatabaseCreation",

 "value": "false",

 "slotSetting": false

 },

 {

 "name": "Imp_EnableMigration",

 "value": "true",

 "slotSetting": false

 },

 {

 "name": "Imp_MigrationKey",

 "value": "xxx",

 "slotSetting": false

 },

 {

 "name": "Imp_TrustSelfSignedCertificate",

 "value": "true",

 "slotSetting": false

 },

 {

 "name": "Imp_UseEnvironmentVars",

 "value": "true",

 "slotSetting": false

 },

 {

 "name": "Imp_UseEnvironmentVarsMode",

 "value": "Process",

 "slotSetting": false

 }

Download Publish Settings From Azure

12.png

Get the deployment package

Download the deployment packages for the WebAPI from the Strusoft Installer. They are available under “Service Configuration”.

1742823416307-522.png

Publishing using VS Code

Use Visual Studio Code with the Azure App Service extension.

1742830976229-725.png

Rightclick and Deploy to Web App....

Choose the Out folder in the WebApi

Unzip the webApi and you can find it way down in the structure.

ex.

.\IMPACT WebAPI 17.2.001\Content\D_C\work\5dbfeae2df21c7d9\impact-web-services\Strusoft.Impact.WebService.Host.IIS\obj\Release\net8.0\PubTmp\Out

Error handling

If you get a error it can sometimes be helpfull to add the ASPNETCORE_DETAILEDERRORS variable and set it to true. That way you can see the error on the webpage.

If you get a timeout error when migrating it can be best using service configuration tool instead. Since Azure will timeout when the database is large.