Install - .NET Agent Controller on Azure App Services for Dynamic Analysis
Overview
The vFunction Dynamic Analysis Controller can be configured for a manual or automatic installation.
In a manual
installation, the vFunction Dynamic Analysis Controller is always staged. But, it it only running when an Administrator runs the installation script in the Azure App Services Console. This means that, if a new version of the Application is deployed to Azure App Services or if the Application is restarted, the vFunction Dynamic Analysis Controller will need to be manually installed again.
In an automatic
installation, the vFunction Controller process is added to the repository of the Application. As part of the Application’s startup process in Azure App Services, the vFunction Dynamic Analysis Controller is launched when the Application is deployed. This means that the vFunction Dynamic Analysis Controller will always be running with the Application in Azure App Services.
Manual Installation
Notes
The installation workflow below will require you to update the install-controller.ps1
if you do not want to use the default locations. You would want to do this if:
- You want to use a different directory than
C:\home\vfunction-stuff
as the location for the vFunction Configuration Files - You want to use a different directory than
C:\home\vfunction
as the vFunction Installation location
Installation Workflow
- Ensure prerequisites are met
- Download the vFunction Controller Windows Installation ZIP
- Rename this ZIP to be 'vfunction-controller-windows-installation.zip'
- Download the vFunction Azure App Services Sample Installation Guide
- Untar the vFunction Azure App Services Sample Installation Guide
tar xvf 'Installing vFunction Controller on Azure App Services_Version-2.tgz'
- Open the vfunction-controller-in-application-azure-app-services/config/
installation.yaml
in a text editor - Modify the required settings as well as the instance_id and application_name
- Log into the Azure App Services Portal
- Navigate to the Application's Configuration > Application Settings
- Create six new Application Settings
.NET Core 3.x and .NET 6 / 7 / 8 Applications - CORECLR_ENABLE_PROFILING = 1
- DOTNET_TailCallOpt = 0
- CORECLR_PROFILER = {cd7d4b53-96c8-4552-9c11-6e41df8eab8a}
- CORECLR_PROFILER_PATH_32 = C:\\home\\vfunction\\agent\\vfagent.net.x86.dll
- CORECLR_PROFILER_PATH_64 = C:\\home\\vfunction\\agent\\vfagent.net.dll
- VF_AGENT_CONF_LOCATION = C:\\home\\vfunction\\config\\agent\\instances\\default-dotnet\\conf.json
.NET Framework 4.x Applications - COR_ENABLE_PROFILING = 1
- COMPlus_TailCallOpt = 0
- COR_PROFILER = {cd7d4b53-96c8-4552-9c11-6e41df8eab8a}
- COR_PROFILER_PATH_32 = C:\\home\\vfunction\\agent\\vfagent.net.x86.dll
- COR_PROFILER_PATH_64 = C:\\home\\vfunction\\agent\\vfagent.net.dll
- VF_AGENT_CONF_LOCATION = C:\\home\\vfunction\\config\\agent\\instances\\default-dotnet\\conf.json
- Save the Application Settings and wait for the Application to restart
- Open the Kudu Dashboard
- Create a folder named 'vfunction-stuff' in
C:\home
- Into the folder, upload the:
- vfunction-controller-in-application-azure-app-services/config/
installation.yaml
- vfunction-controller-in-application-azure-app-services/config/
global.yaml
- vfunction-controller-in-application-azure-app-services/files/
install-controller.ps1
vfunction-controller-windows-installation.zip
- vfunction-controller-in-application-azure-app-services/config/
- Open the PowerShell Debug Console in the Kudu Dashboard
- Install the vFunction Dynamic Analysis Controller by running the following command in PowerShell
C:\home\vfunction-stuff\install-controller.ps1
- Confirm that the Application comes up and functions as expected
- If any issues arise:
Automatic Installation
Notes
The installation workflow below will require you to update the deploy.cmd
if you do not want to use the default locations. You would want to do this if:
- You want to use a different directory than
ROOT/vfunction-stuff
as the location for the vFunction Configuration Files - You want to use a different directory than
ROOT/wwwroot
as the vFunction Installation location
Installation Workflow
- Ensure prerequisites are met
- Download the vFunction Controller Windows Installation ZIP
- Rename this ZIP to be 'vfunction-controller-windows-installation.zip'
- Download the vFunction Azure App Services Sample Installation Guide
- Untar the vFunction Azure App Services Sample Installation Guide
tar xvf 'Installing vFunction Controller on Azure App Services_Version-2.tgz'
- Open the vfunction-controller-in-application-azure-app-services/config/
installation.yaml
in a text editor - Modify the required settings as well as the instance_id and application_name
- Log into the Azure App Services Portal
- Navigate to the Application's Configuration > Application Settings
- Create six new Application Settings
.NET Core 3.x and .NET 6 / 7 / 8 Applications - CORECLR_ENABLE_PROFILING = 1
- DOTNET_TailCallOpt = 0
- CORECLR_PROFILER = {cd7d4b53-96c8-4552-9c11-6e41df8eab8a}
- CORECLR_PROFILER_PATH_32 = C:\\home\\vfunction\\agent\\vfagent.net.x86.dll
- CORECLR_PROFILER_PATH_64 = C:\\home\\vfunction\\agent\\vfagent.net.dll
- VF_AGENT_CONF_LOCATION = C:\\home\\vfunction\\config\\agent\\instances\\default-dotnet\\conf.json
.NET Framework 4.x Applications - COR_ENABLE_PROFILING = 1
- COMPlus_TailCallOpt = 0
- COR_PROFILER = {cd7d4b53-96c8-4552-9c11-6e41df8eab8a}
- COR_PROFILER_PATH_32 = C:\\home\\vfunction\\agent\\vfagent.net.x86.dll
- COR_PROFILER_PATH_64 = C:\\home\\vfunction\\agent\\vfagent.net.dll
- VF_AGENT_CONF_LOCATION = C:\\home\\vfunction\\config\\agent\\instances\\default-dotnet\\conf.json
- Save the Application Settings and wait for the Application to restart
- Open your project's root directory for the Application in your code editor of choice
- Copy the following files into the project's root directory:
- vfunction-controller-in-application-azure-app-services/files/
.deployment
- vfunction-controller-in-application-azure-app-services/files/
deploy.cmd
- vfunction-controller-in-application-azure-app-services/files/
- Create a folder named 'vfunction-stuff' in the project's root directory
- Into the folder, upload the:
- vfunction-controller-in-application-azure-app-services/config/
installation.yaml
- vfunction-controller-in-application-azure-app-services/config/
global.yaml
vfunction-controller-windows-installation.zip
- vfunction-controller-in-application-azure-app-services/config/
- Deploy your application to Azure App Services
- Confirm that the Application comes up and functions as expected
- If any issues arise: