From 59d844a64d556b4704473ecc078ea3a76f6b8369 Mon Sep 17 00:00:00 2001 From: Tommy Parnell Date: Fri, 29 Apr 2016 10:45:29 -0400 Subject: [PATCH] allow specification of app pool attributes --- QuikPak/Config.cs | 36 +++++++++++++++++------------- QuikPak/Program.cs | 10 ++++++++- QuikPak/Properties/AssemblyInfo.cs | 14 ++++++------ 3 files changed, 37 insertions(+), 23 deletions(-) diff --git a/QuikPak/Config.cs b/QuikPak/Config.cs index d5f5708..ec75a40 100644 --- a/QuikPak/Config.cs +++ b/QuikPak/Config.cs @@ -6,19 +6,25 @@ using System.Threading.Tasks; namespace QuikPak { - public class Config - { - public string Id { get; set; } - public string UpgradeCode { get; set; } - public string Name { get; set; } - public string Version { get; set; } - public ICollection Endpoints { get; set; } - } + public class Config + { + public string Id { get; set; } + public string UpgradeCode { get; set; } + public string Name { get; set; } + public string Version { get; set; } + public ICollection Endpoints { get; set; } - public class Endpoint - { - public int Port { get; set; } - public string DnsName { get; set; } - public bool Secure { get; set; } = false; - } -} + public string Identity { get; set; } = "localSystem"; + public int RecycleMinutes { get; set; } = 0; + public int IdleTimeout { get; set; } = 0; + public string ManagedPipelineMode { get; set; } = "Intergrated"; + public string ManagedRuntimeVersion { get; set; } = "v4.0"; + } + + public class Endpoint + { + public int Port { get; set; } + public string DnsName { get; set; } + public bool Secure { get; set; } = false; + } +} \ No newline at end of file diff --git a/QuikPak/Program.cs b/QuikPak/Program.cs index 8a8bdd8..4915303 100644 --- a/QuikPak/Program.cs +++ b/QuikPak/Program.cs @@ -60,7 +60,15 @@ namespace QuikPak Description = config.Name, Addresses = addresses.ToArray(), }, - WebAppPool = new WebAppPool(config.Name) + WebAppPool = new WebAppPool(config.Name) { + Attributes = new Dictionary() { + ["Identity"] = config.Identity, + ["RecycleMinutes"] = config.RecycleMinutes.ToString(), + ["IdleTimeout"] = config.IdleTimeout.ToString(), + ["ManagedPipelineMode"] = config.ManagedPipelineMode, + ["ManagedRuntimeVersion"] = config.ManagedRuntimeVersion + } + } }) ) }, diff --git a/QuikPak/Properties/AssemblyInfo.cs b/QuikPak/Properties/AssemblyInfo.cs index e3df4b4..94485bd 100644 --- a/QuikPak/Properties/AssemblyInfo.cs +++ b/QuikPak/Properties/AssemblyInfo.cs @@ -2,7 +2,7 @@ using System.Runtime.CompilerServices; using System.Runtime.InteropServices; -// General Information about an assembly is controlled through the following +// General Information about an assembly is controlled through the following // set of attributes. Change these attribute values to modify the information // associated with an assembly. [assembly: AssemblyTitle("QuikPak")] @@ -14,8 +14,8 @@ using System.Runtime.InteropServices; [assembly: AssemblyTrademark("")] [assembly: AssemblyCulture("")] -// Setting ComVisible to false makes the types in this assembly not visible -// to COM components. If you need to access a type in this assembly from +// Setting ComVisible to false makes the types in this assembly not visible +// to COM components. If you need to access a type in this assembly from // COM, set the ComVisible attribute to true on that type. [assembly: ComVisible(false)] @@ -25,12 +25,12 @@ using System.Runtime.InteropServices; // Version information for an assembly consists of the following four values: // // Major Version -// Minor Version +// Minor Version // Build Number // Revision // -// You can specify all the values or you can default the Build and Revision Numbers +// You can specify all the values or you can default the Build and Revision Numbers // by using the '*' as shown below: // [assembly: AssemblyVersion("1.0.*")] -[assembly: AssemblyVersion("1.0.0.0")] -[assembly: AssemblyFileVersion("1.0.0.0")] +[assembly: AssemblyVersion("0.6.0.0")] +[assembly: AssemblyFileVersion("0.6.0.0")] \ No newline at end of file