private static string GetLocalResourcePathAndSetAccess(string localResourceName) { var resourcePath = AzureRoleEnvironment.GetLocalResourcePath(localResourceName); var localDataSec = Directory.GetAccessControl(resourcePath); localDataSec.AddAccessRule(new FileSystemAccessRule(new SecurityIdentifier(WellKnownSidType.WorldSid, null), FileSystemRights.FullControl, InheritanceFlags.ContainerInherit | InheritanceFlags.ObjectInherit, PropagationFlags.None, AccessControlType.Allow)); Directory.SetAccessControl(resourcePath, localDataSec); return(resourcePath); }
public static string GetExecutionLocalResourcePath() { return(AzureRoleEnvironment.GetLocalResourcePath(ExecutionLocalResource)); }
public static string GetSitesLocalResourcePath() { return(AzureRoleEnvironment.GetLocalResourcePath(SitesLocalResource)); }