林豪 左 2 years ago
parent
commit
39e4c08536

+ 5 - 5
NuGetServer.sln

@@ -3,7 +3,7 @@ Microsoft Visual Studio Solution File, Format Version 12.00
 # Visual Studio Version 17
 VisualStudioVersion = 17.5.33627.172
 MinimumVisualStudioVersion = 10.0.40219.1
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NuGetServer", "NuGetServer\NuGetServer.csproj", "{2BF6F4EE-E758-4FE6-9C4E-2274B75C6DCD}"
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "NuGetServer", "NuGetServer1\NuGetServer.csproj", "{97AA2F3A-00B8-4225-AB98-D35581FA6713}"
 EndProject
 Global
 	GlobalSection(SolutionConfigurationPlatforms) = preSolution
@@ -11,10 +11,10 @@ Global
 		Release|Any CPU = Release|Any CPU
 	EndGlobalSection
 	GlobalSection(ProjectConfigurationPlatforms) = postSolution
-		{2BF6F4EE-E758-4FE6-9C4E-2274B75C6DCD}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
-		{2BF6F4EE-E758-4FE6-9C4E-2274B75C6DCD}.Debug|Any CPU.Build.0 = Debug|Any CPU
-		{2BF6F4EE-E758-4FE6-9C4E-2274B75C6DCD}.Release|Any CPU.ActiveCfg = Release|Any CPU
-		{2BF6F4EE-E758-4FE6-9C4E-2274B75C6DCD}.Release|Any CPU.Build.0 = Release|Any CPU
+		{97AA2F3A-00B8-4225-AB98-D35581FA6713}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+		{97AA2F3A-00B8-4225-AB98-D35581FA6713}.Debug|Any CPU.Build.0 = Debug|Any CPU
+		{97AA2F3A-00B8-4225-AB98-D35581FA6713}.Release|Any CPU.ActiveCfg = Release|Any CPU
+		{97AA2F3A-00B8-4225-AB98-D35581FA6713}.Release|Any CPU.Build.0 = Release|Any CPU
 	EndGlobalSection
 	GlobalSection(SolutionProperties) = preSolution
 		HideSolutionNode = FALSE

+ 0 - 17
NuGetServer/Web.config

@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<!--
-  有关如何配置 ASP.NET 应用程序的详细信息,请访问
-  https://go.microsoft.com/fwlink/?LinkId=169433
--->
-<configuration>
-  <system.web>
-    <compilation debug="true" targetFramework="4.7.2" />
-    <httpRuntime targetFramework="4.7.2" />
-  </system.web>
-  <system.codedom>
-    <compilers>
-      <compiler language="c#;cs;csharp" extension=".cs" type="Microsoft.CodeDom.Providers.DotNetCompilerPlatform.CSharpCodeProvider, Microsoft.CodeDom.Providers.DotNetCompilerPlatform, Version=2.0.1.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" warningLevel="4" compilerOptions="/langversion:default /nowarn:1659;1699;1701" />
-      <compiler language="vb;vbs;visualbasic;vbscript" extension=".vb" type="Microsoft.CodeDom.Providers.DotNetCompilerPlatform.VBCodeProvider, Microsoft.CodeDom.Providers.DotNetCompilerPlatform, Version=2.0.1.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" warningLevel="4" compilerOptions="/langversion:default /nowarn:41008 /define:_MYTYPE=\&quot;Web\&quot; /optionInfer+" />
-    </compilers>
-  </system.codedom>
-</configuration>

+ 0 - 4
NuGetServer/packages.config

@@ -1,4 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<packages>
-  <package id="Microsoft.CodeDom.Providers.DotNetCompilerPlatform" version="2.0.1" targetFramework="net472" />
-</packages>

+ 42 - 0
NuGetServer1/App_Start/NuGetODataConfig.cs

@@ -0,0 +1,42 @@
+using System.Net.Http;
+using System.Web.Http;
+using System.Web.Http.ExceptionHandling;
+using System.Web.Http.Routing;
+using NuGet.Server;
+using NuGet.Server.Infrastructure;
+using NuGet.Server.V2;
+
+[assembly: WebActivatorEx.PreApplicationStartMethod(typeof(NuGetServer1.App_Start.NuGetODataConfig), "Start")]
+
+namespace NuGetServer1.App_Start 
+{
+    public static class NuGetODataConfig 
+    {
+        public static void Start() 
+        {
+            ServiceResolver.SetServiceResolver(new DefaultServiceResolver());
+
+            var config = GlobalConfiguration.Configuration;
+
+            NuGetV2WebApiEnabler.UseNuGetV2WebApiFeed(
+                config,
+                "NuGetDefault",
+                "nuget",
+                "PackagesOData",
+                enableLegacyPushRoute: true);
+
+            config.Services.Replace(typeof(IExceptionLogger), new TraceExceptionLogger());
+
+            // Trace.Listeners.Add(new TextWriterTraceListener(HostingEnvironment.MapPath("~/NuGet.Server.log")));
+            // Trace.AutoFlush = true;
+
+            config.Routes.MapHttpRoute(
+                name: "NuGetDefault_ClearCache",
+                routeTemplate: "nuget/clear-cache",
+                defaults: new { controller = "PackagesOData", action = "ClearCache" },
+                constraints: new { httpMethod = new HttpMethodConstraint(HttpMethod.Get) }
+            );
+
+        }
+    }
+}

+ 49 - 0
NuGetServer1/Default.aspx

@@ -0,0 +1,49 @@
+<%@ Page Language="C#" %>
+<%@ Import Namespace="NuGet.Server" %>
+<%@ Import Namespace="NuGet.Server.App_Start" %>
+<%@ Import Namespace="NuGet.Server.Infrastructure" %>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head id="Head1" runat="server">
+    <title>NuGet Private Repository</title>
+    <style>
+        body { font-family: Calibri; }
+    </style>
+</head>
+<body>
+    <div>
+        <h2>You are running NuGet.Server v<%= typeof(NuGetODataConfig).Assembly.GetName().Version %></h2>
+        <p>
+            Click <a href="<%= VirtualPathUtility.ToAbsolute("~/nuget/Packages") %>">here</a> to view your packages.
+        </p>
+        <fieldset style="width:800px">
+            <legend><strong>Repository URLs</strong></legend>
+            In the package manager settings, add the following URL to the list of 
+            Package Sources:
+            <blockquote>
+                <strong><%= Helpers.GetRepositoryUrl(Request.Url, Request.ApplicationPath) %></strong>
+            </blockquote>
+            <% if (string.IsNullOrEmpty(ConfigurationManager.AppSettings["apiKey"])) { %>
+            To enable pushing packages to this feed using the <a href="https://www.nuget.org/downloads">NuGet command line tool</a> (nuget.exe), set the <code>apiKey</code> appSetting in web.config.
+            <% } else { %>
+            Use the command below to push packages to this feed using the <a href="https://www.nuget.org/downloads">NuGet command line tool</a> (nuget.exe).
+            <blockquote>
+                <strong>nuget.exe push {package file} {apikey} -Source <%= Helpers.GetPushUrl(Request.Url, Request.ApplicationPath) %></strong>
+            </blockquote>
+            <% } %> 
+        </fieldset>
+
+        <% if (Request.IsLocal || ServiceResolver.Current.Resolve<NuGet.Server.Core.Infrastructure.ISettingsProvider>().GetBoolSetting("allowRemoteCacheManagement", false)) { %>
+        <fieldset style="width:800px">
+            <legend><strong>Adding packages</strong></legend>
+
+            To add packages to the feed put package files (.nupkg files) in the folder
+            <code><% = PackageUtility.PackagePhysicalPath %></code><br/><br/>
+
+            Click <a href="<%= VirtualPathUtility.ToAbsolute("~/nuget/clear-cache") %>">here</a> to clear the package cache.
+        </fieldset>
+        <% } %>
+    </div>
+</body>
+</html>

+ 61 - 7
NuGetServer/NuGetServer.csproj → NuGetServer1/NuGetServer.csproj

@@ -7,16 +7,16 @@
     <ProductVersion>
     </ProductVersion>
     <SchemaVersion>2.0</SchemaVersion>
-    <ProjectGuid>{2BF6F4EE-E758-4FE6-9C4E-2274B75C6DCD}</ProjectGuid>
+    <ProjectGuid>{97AA2F3A-00B8-4225-AB98-D35581FA6713}</ProjectGuid>
     <ProjectTypeGuids>{349c5851-65df-11da-9384-00065b846f21};{fae04ec0-301f-11d3-bf4b-00c04f79efbc}</ProjectTypeGuids>
     <OutputType>Library</OutputType>
     <AppDesignerFolder>Properties</AppDesignerFolder>
-    <RootNamespace>NuGetServer</RootNamespace>
-    <AssemblyName>NuGetServer</AssemblyName>
-    <TargetFrameworkVersion>v4.7.2</TargetFrameworkVersion>
+    <RootNamespace>NuGetServer1</RootNamespace>
+    <AssemblyName>NuGetServer1</AssemblyName>
+    <TargetFrameworkVersion>v4.6</TargetFrameworkVersion>
     <UseIISExpress>true</UseIISExpress>
     <Use64BitIISExpress />
-    <IISExpressSSLPort>44355</IISExpressSSLPort>
+    <IISExpressSSLPort>44393</IISExpressSSLPort>
     <IISExpressAnonymousAuthentication />
     <IISExpressWindowsAuthentication />
     <IISExpressUseClassicPipelineMode />
@@ -44,6 +44,44 @@
   </PropertyGroup>
   <ItemGroup>
     <Reference Include="Microsoft.CSharp" />
+    <Reference Include="Microsoft.Data.Edm, Version=5.8.4.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
+      <HintPath>..\packages\Microsoft.Data.Edm.5.8.4\lib\net40\Microsoft.Data.Edm.dll</HintPath>
+    </Reference>
+    <Reference Include="Microsoft.Data.OData, Version=5.8.4.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
+      <HintPath>..\packages\Microsoft.Data.OData.5.8.4\lib\net40\Microsoft.Data.OData.dll</HintPath>
+    </Reference>
+    <Reference Include="Microsoft.Web.Infrastructure, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
+      <HintPath>..\packages\Microsoft.Web.Infrastructure.1.0.0.0\lib\net40\Microsoft.Web.Infrastructure.dll</HintPath>
+    </Reference>
+    <Reference Include="Microsoft.Web.XmlTransform, Version=2.1.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
+      <HintPath>..\packages\Microsoft.Web.Xdt.2.1.1\lib\net40\Microsoft.Web.XmlTransform.dll</HintPath>
+    </Reference>
+    <Reference Include="Newtonsoft.Json, Version=13.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
+      <HintPath>..\packages\Newtonsoft.Json.13.0.1\lib\net45\Newtonsoft.Json.dll</HintPath>
+    </Reference>
+    <Reference Include="NuGet.Core, Version=2.14.0.832, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
+      <HintPath>..\packages\NuGet.Core.2.14.0\lib\net40-Client\NuGet.Core.dll</HintPath>
+    </Reference>
+    <Reference Include="NuGet.Server, Version=3.4.2.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
+      <HintPath>..\packages\NuGet.Server.3.4.2\lib\net46\NuGet.Server.dll</HintPath>
+    </Reference>
+    <Reference Include="NuGet.Server.Core, Version=3.4.2.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
+      <HintPath>..\packages\NuGet.Server.Core.3.4.2\lib\net46\NuGet.Server.Core.dll</HintPath>
+    </Reference>
+    <Reference Include="NuGet.Server.V2, Version=3.4.2.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
+      <HintPath>..\packages\NuGet.Server.V2.3.4.2\lib\net46\NuGet.Server.V2.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Data.Services" />
+    <Reference Include="System.Net.Http" />
+    <Reference Include="System.Net.Http.Formatting, Version=5.2.3.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
+      <HintPath>..\packages\Microsoft.AspNet.WebApi.Client.5.2.3\lib\net45\System.Net.Http.Formatting.dll</HintPath>
+    </Reference>
+    <Reference Include="System.ServiceModel" />
+    <Reference Include="System.ServiceModel.Activation" />
+    <Reference Include="System.ServiceModel.Web" />
+    <Reference Include="System.Spatial, Version=5.8.4.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
+      <HintPath>..\packages\System.Spatial.5.8.4\lib\net40\System.Spatial.dll</HintPath>
+    </Reference>
     <Reference Include="System.Web.DynamicData" />
     <Reference Include="System.Web.Entity" />
     <Reference Include="System.Web.ApplicationServices" />
@@ -53,6 +91,15 @@
     <Reference Include="System.Core" />
     <Reference Include="System.Data.DataSetExtensions" />
     <Reference Include="System.Web.Extensions" />
+    <Reference Include="System.Web.Http, Version=5.2.3.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
+      <HintPath>..\packages\Microsoft.AspNet.WebApi.Core.5.2.3\lib\net45\System.Web.Http.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Web.Http.OData, Version=5.7.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
+      <HintPath>..\packages\Microsoft.AspNet.WebApi.OData.5.7.0\lib\net45\System.Web.Http.OData.dll</HintPath>
+    </Reference>
+    <Reference Include="System.Web.Http.WebHost, Version=5.2.3.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
+      <HintPath>..\packages\Microsoft.AspNet.WebApi.WebHost.5.2.3\lib\net45\System.Web.Http.WebHost.dll</HintPath>
+    </Reference>
     <Reference Include="System.Xml.Linq" />
     <Reference Include="System.Drawing" />
     <Reference Include="System.Web" />
@@ -60,6 +107,9 @@
     <Reference Include="System.Configuration" />
     <Reference Include="System.Web.Services" />
     <Reference Include="System.EnterpriseServices" />
+    <Reference Include="WebActivatorEx, Version=2.0.0.0, Culture=neutral, PublicKeyToken=7b26dc2a43f6a0d4, processorArchitecture=MSIL">
+      <HintPath>..\packages\WebActivatorEx.2.2.0\lib\net40\WebActivatorEx.dll</HintPath>
+    </Reference>
   </ItemGroup>
   <ItemGroup>
     <Reference Include="Microsoft.CodeDom.Providers.DotNetCompilerPlatform">
@@ -67,9 +117,13 @@
     </Reference>
   </ItemGroup>
   <ItemGroup>
+    <Content Include="Default.aspx" />
+    <Content Include="favicon.ico" />
+    <Content Include="Packages\Readme.txt" />
     <Content Include="Web.config" />
   </ItemGroup>
   <ItemGroup>
+    <Compile Include="App_Start\NuGetODataConfig.cs" />
     <Compile Include="Properties\AssemblyInfo.cs" />
   </ItemGroup>
   <ItemGroup>
@@ -94,9 +148,9 @@
         <WebProjectProperties>
           <UseIIS>True</UseIIS>
           <AutoAssignPort>True</AutoAssignPort>
-          <DevelopmentServerPort>61898</DevelopmentServerPort>
+          <DevelopmentServerPort>63027</DevelopmentServerPort>
           <DevelopmentServerVPath>/</DevelopmentServerVPath>
-          <IISUrl>https://localhost:44355/</IISUrl>
+          <IISUrl>https://localhost:44393/</IISUrl>
           <NTLMAuthentication>False</NTLMAuthentication>
           <UseCustomServer>False</UseCustomServer>
           <CustomServerUrl>

+ 3 - 3
NuGetServer/Properties/AssemblyInfo.cs → NuGetServer1/Properties/AssemblyInfo.cs

@@ -5,11 +5,11 @@ using System.Runtime.InteropServices;
 // 有关程序集的常规信息通过下列特性集
 // 控制。更改这些特性值可修改
 // 与程序集关联的信息。
-[assembly: AssemblyTitle("NuGetServer")]
+[assembly: AssemblyTitle("NuGetServer1")]
 [assembly: AssemblyDescription("")]
 [assembly: AssemblyConfiguration("")]
 [assembly: AssemblyCompany("")]
-[assembly: AssemblyProduct("NuGetServer")]
+[assembly: AssemblyProduct("NuGetServer1")]
 [assembly: AssemblyCopyright("Copyright ©  2023")]
 [assembly: AssemblyTrademark("")]
 [assembly: AssemblyCulture("")]
@@ -20,7 +20,7 @@ using System.Runtime.InteropServices;
 [assembly: ComVisible(false)]
 
 // 如果此项目向 COM 公开,则下列 GUID 用于 typelib 的 ID
-[assembly: Guid("2bf6f4ee-e758-4fe6-9c4e-2274b75c6dcd")]
+[assembly: Guid("97aa2f3a-00b8-4225-ab98-d35581fa6713")]
 
 // 程序集的版本信息由下列四个值组成:
 //

+ 0 - 0
NuGetServer/Web.Debug.config → NuGetServer1/Web.Debug.config


+ 0 - 0
NuGetServer/Web.Release.config → NuGetServer1/Web.Release.config


+ 156 - 0
NuGetServer1/Web.config

@@ -0,0 +1,156 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+  有关如何配置 ASP.NET 应用程序的详细信息,请访问
+  https://go.microsoft.com/fwlink/?LinkId=169433
+-->
+<configuration>
+  <!--
+    For a description of web.config changes see http://go.microsoft.com/fwlink/?LinkId=235367.
+
+    The following attributes can be set on the <httpRuntime> tag.
+      <system.Web>
+        <httpRuntime targetFramework="4.6" />
+      </system.Web>
+  -->
+  <system.web>
+    <compilation debug="true" targetFramework="4.6" />
+    <!-- maxRequestLength is specified in Kb -->
+    <httpRuntime targetFramework="4.6" maxRequestLength="30720" />
+  </system.web>
+  <system.codedom>
+    <compilers>
+      <compiler language="c#;cs;csharp" extension=".cs" type="Microsoft.CodeDom.Providers.DotNetCompilerPlatform.CSharpCodeProvider, Microsoft.CodeDom.Providers.DotNetCompilerPlatform, Version=2.0.1.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" warningLevel="4" compilerOptions="/langversion:default /nowarn:1659;1699;1701" />
+      <compiler language="vb;vbs;visualbasic;vbscript" extension=".vb" type="Microsoft.CodeDom.Providers.DotNetCompilerPlatform.VBCodeProvider, Microsoft.CodeDom.Providers.DotNetCompilerPlatform, Version=2.0.1.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" warningLevel="4" compilerOptions="/langversion:default /nowarn:41008 /define:_MYTYPE=\&quot;Web\&quot; /optionInfer+" />
+    </compilers>
+  </system.codedom>
+  <system.webServer>
+    <handlers>
+      <remove name="ExtensionlessUrlHandler-Integrated-4.0" />
+      <remove name="OPTIONSVerbHandler" />
+      <remove name="TRACEVerbHandler" />
+      <add name="ExtensionlessUrlHandler-Integrated-4.0" path="*." verb="*" type="System.Web.Handlers.TransferRequestHandler" preCondition="integratedMode,runtimeVersionv4.0" />
+      <remove name="WebDAV" />
+      <!-- Depending on IIS configuration, these may have to be added.
+      <remove name="ExtensionlessUrlHandler-Integrated-4.0" />
+      <add name="ExtensionlessUrlHandler-Integrated-4.0" path="*." verb="GET,HEAD,POST,PUT,DEBUG" type="System.Web.Handlers.TransferRequestHandler" preCondition="integratedMode,runtimeVersionv4.0" />
+      <remove name="OPTIONSVerbHandler" /><remove name="TRACEVerbHandler" />
+      <add name="ExtensionlessUrlHandler-Integrated-4.0" path="*." verb="*" type="System.Web.Handlers.TransferRequestHandler" preCondition="integratedMode,runtimeVersionv4.0" />
+      -->
+    </handlers>
+    <staticContent>
+      <mimeMap fileExtension=".nupkg" mimeType="application/zip" />
+    </staticContent>
+    <modules runAllManagedModulesForAllRequests="true">
+      <remove name="WebDAVModule" />
+    </modules>
+    <security>
+      <requestFiltering>
+        <!-- maxAllowedContentLength is specified in Bytes -->
+        <requestLimits maxAllowedContentLength="31457280" />
+      </requestFiltering>
+    </security>
+  </system.webServer>
+  <appSettings>
+    <!--
+    Determines if an Api Key is required to push\delete packages from the server. 
+    -->
+    <add key="requireApiKey" value="true" />
+    <!-- 
+    Set the value here to allow people to push/delete packages from the server.
+    NOTE: This is a shared key (password) for all users.
+    -->
+    <add key="apiKey" value="7166766" />
+    <!--
+    Change the path to the packages folder. Default is ~/Packages.
+    This can be a virtual or physical path.
+    -->
+    <add key="packagesPath" value="" />
+    <!--
+    Change the name of the internal cache file. Default is machine name (System.Environment.MachineName).
+    This is the name of the cache file in the packages folder. No paths allowed.
+    -->
+    <add key="cacheFileName" value="" />
+    <!--
+    Set allowOverrideExistingPackageOnPush to false to mimic NuGet.org's behaviour (do not allow overwriting packages with same id + version).
+    -->
+    <add key="allowOverrideExistingPackageOnPush" value="false" />
+    <!--
+    Set ignoreSymbolsPackages to true to filter out symbols packages. Since NuGet.Server does not come with a symbol server,
+    it makes sense to ignore this type of packages. When enabled, files named `.symbols.nupkg` or packages containing a `/src` folder will be ignored.
+    
+    If you only push .symbols.nupkg packages, set this to false so that packages can be uploaded.
+    -->
+    <add key="ignoreSymbolsPackages" value="true" />
+    <!--
+    Set enableDelisting to true to enable delist instead of delete as a result of a "nuget delete" command.
+    - delete: package is deleted from the repository's local filesystem.
+    - delist: 
+      - "nuget delete": the "hidden" file attribute of the corresponding nupkg on the repository local filesystem is turned on instead of deleting the file.
+      - "nuget list" skips delisted packages, i.e. those that have the hidden attribute set on their nupkg.
+      - "nuget install packageid -version version" command will succeed for both listed and delisted packages.
+        e.g. delisted packages can still be downloaded by clients that explicitly specify their version.
+    -->
+    <add key="enableDelisting" value="false" />
+    <!--
+    Set enableFrameworkFiltering to true to enable filtering packages by their supported frameworks during search.
+    -->
+    <add key="enableFrameworkFiltering" value="false" />
+    <!--
+    When running NuGet.Server in a NAT network, ASP.NET may embed the server's internal IP address in the V2 feed.
+    Uncomment the following configuration entry to enable NAT support.
+    -->
+    <!-- <add key="aspnet:UseHostHeaderForRequestUrl" value="true" /> -->
+    <!--
+    Set enableFileSystemMonitoring to true (default) to enable file system monitoring (which will update the package cache appropriately on file system changes).
+    Set it to false to disable file system monitoring.
+    NOTE: Disabling file system monitoring may result in increased storage capacity requirements as package cache may only be purged by a background job running 
+    on a fixed 1-hour interval.
+    -->
+    <add key="enableFileSystemMonitoring" value="true" />
+    <!--
+    Set allowRemoteCacheManagement to true to enable the "clear cache" and other cache operations initiated via requests originating from remote hosts.
+    -->
+    <add key="allowRemoteCacheManagement" value="false" />
+    <!--
+    Set initialCacheRebuildAfterSeconds to the number of seconds to wait before starting the cache rebuild timer.
+    Defaults to 15 seconds if excluded or an invalid value.
+    -->
+    <add key="initialCacheRebuildAfterSeconds" value="15" />
+    <!--
+    Set cacheRebuildFrequencyInMinutes to the frequency in minutes to rebuild the cache. Defaults to 60 minutes if
+    excluded or an invalid value.
+    -->
+    <add key="cacheRebuildFrequencyInMinutes" value="60" />
+  </appSettings>
+  <system.serviceModel>
+    <serviceHostingEnvironment aspNetCompatibilityEnabled="true" />
+  </system.serviceModel>
+  <runtime>
+    <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
+      <dependentAssembly>
+        <assemblyIdentity name="Newtonsoft.Json" publicKeyToken="30ad4fe6b2a6aeed" culture="neutral" />
+        <bindingRedirect oldVersion="0.0.0.0-13.0.0.0" newVersion="13.0.0.0" />
+      </dependentAssembly>
+      <dependentAssembly>
+        <assemblyIdentity name="System.Web.Http" publicKeyToken="31bf3856ad364e35" culture="neutral" />
+        <bindingRedirect oldVersion="0.0.0.0-5.2.3.0" newVersion="5.2.3.0" />
+      </dependentAssembly>
+      <dependentAssembly>
+        <assemblyIdentity name="System.Net.Http.Formatting" publicKeyToken="31bf3856ad364e35" culture="neutral" />
+        <bindingRedirect oldVersion="0.0.0.0-5.2.3.0" newVersion="5.2.3.0" />
+      </dependentAssembly>
+      <dependentAssembly>
+        <assemblyIdentity name="Microsoft.Data.Edm" publicKeyToken="31bf3856ad364e35" culture="neutral" />
+        <bindingRedirect oldVersion="0.0.0.0-5.8.4.0" newVersion="5.8.4.0" />
+      </dependentAssembly>
+      <dependentAssembly>
+        <assemblyIdentity name="Microsoft.Data.OData" publicKeyToken="31bf3856ad364e35" culture="neutral" />
+        <bindingRedirect oldVersion="0.0.0.0-5.8.4.0" newVersion="5.8.4.0" />
+      </dependentAssembly>
+      <dependentAssembly>
+        <assemblyIdentity name="System.Spatial" publicKeyToken="31bf3856ad364e35" culture="neutral" />
+        <bindingRedirect oldVersion="0.0.0.0-5.8.4.0" newVersion="5.8.4.0" />
+      </dependentAssembly>
+    </assemblyBinding>
+  </runtime>
+</configuration>

BIN
NuGetServer1/favicon.ico


+ 20 - 0
NuGetServer1/packages.config

@@ -0,0 +1,20 @@
+<?xml version="1.0" encoding="utf-8"?>
+<packages>
+  <package id="Microsoft.AspNet.WebApi" version="5.2.3" targetFramework="net46" />
+  <package id="Microsoft.AspNet.WebApi.Client" version="5.2.3" targetFramework="net46" />
+  <package id="Microsoft.AspNet.WebApi.Core" version="5.2.3" targetFramework="net46" />
+  <package id="Microsoft.AspNet.WebApi.OData" version="5.7.0" targetFramework="net46" />
+  <package id="Microsoft.AspNet.WebApi.WebHost" version="5.2.3" targetFramework="net46" />
+  <package id="Microsoft.CodeDom.Providers.DotNetCompilerPlatform" version="2.0.1" targetFramework="net46" />
+  <package id="Microsoft.Data.Edm" version="5.8.4" targetFramework="net46" />
+  <package id="Microsoft.Data.OData" version="5.8.4" targetFramework="net46" />
+  <package id="Microsoft.Web.Infrastructure" version="1.0.0.0" targetFramework="net46" />
+  <package id="Microsoft.Web.Xdt" version="2.1.1" targetFramework="net46" />
+  <package id="Newtonsoft.Json" version="13.0.1" targetFramework="net46" />
+  <package id="NuGet.Core" version="2.14.0" targetFramework="net46" />
+  <package id="NuGet.Server" version="3.4.2" targetFramework="net46" />
+  <package id="NuGet.Server.Core" version="3.4.2" targetFramework="net46" />
+  <package id="NuGet.Server.V2" version="3.4.2" targetFramework="net46" />
+  <package id="System.Spatial" version="5.8.4" targetFramework="net46" />
+  <package id="WebActivatorEx" version="2.2.0" targetFramework="net46" />
+</packages>