Previous SDK Already Exists check failed upon testing in App Service Linux environments as there were instances of the old agent that broke my check.
New check looks for the "applicationinsights" package specifically under the "/home/site/wwwroot" path on Node versions > 8.9 (where the paths parameter was introduced).
Tested this change detects the path of the user's SDK in both Windows and Linux App Services from multiple starting paths inside and outside of the "/home" path. Also ensured that the check fails as expected if the application deployed to the App Service does not include the applicationinsights package.
Previous SDK Already Exists check failed upon testing in App Service Linux environments as there were instances of the old agent that broke my check.
New check looks for the "applicationinsights" package specifically under the "/home/site/wwwroot" path on Node versions > 8.9 (where the
paths
parameter was introduced).Tested this change detects the path of the user's SDK in both Windows and Linux App Services from multiple starting paths inside and outside of the "/home" path. Also ensured that the check fails as expected if the application deployed to the App Service does not include the
applicationinsights
package.