title: How to check Azure function is running on local environment? `RoleEnvironment` is not working in Azure Functions
body: <p>I have a condition in code where i need to check if current environment is not local.i have used  <code>!RoleEnvironment.IsEmulated</code>, now this is not working in Azure functions but works in Cloud service. Same code is Shared in Cloud service also, so solution should work with cloud service and azure functions.</p>
  
  <p>how can i check current environment is local not hosted/deployed? </p>