0

We are working in private repository for our own private nuget packages in ASP.NET Project . We are in a position to change the nuget feed for every customer. But nuget packages are located in a location which is specified in Web.Config.

Is there a possibility to change the location dynamically through routing(URL) ? i have refferd this blog http://blog.maartenballiauw.be/post/2011/05/09/Using-dynamic-WCF-service-routes.aspx even though the packages url refers the path given in the webconfig file

public static void MapNugetRoutes(RouteCollection routes)
            {
                var factory = new DataServiceHostFactory();
                var serviceRoute = new ServiceRoute("nuget/packages/getpackages/{platform}", factory, typeof(Packages));
                serviceRoute.Defaults = new RouteValueDictionary { { "serviceType", "odata" } };
                serviceRoute.Constraints = new RouteValueDictionary { { "serviceType", "odata" } };
                routes.Add("nuget", serviceRoute);
}

<appSettings>
    <add key="requireApiKey" value="true" />
    <add key="apiKey" value="" />
    <add key="packagesPath" value="~/NugetPackages/" />
    <add key="enableSimpleMembership" value="false" />
    <add key="" />
  </appSettings>

the "NugetPackages" is my local repositary address , i need to access the repositary privately , like there are several folders inside that above location, i need dynamically access that folders NugetPackages/folder1, NugetPackages/folder2 like this, Is it possible?

thanks in advance..

Anandh
  • 167
  • 5
  • 15
  • 1
    Hi, Please suggest this above queries possible in nuget server . last 2 days i am sticking in this. – Anandh Feb 14 '15 at 04:48
  • Identical question asked and answered here: http://stackoverflow.com/questions/28470892/nuget-server-private-repository-change-package-location-dynamically?rq=1 – Rob Johnston May 03 '16 at 16:42

0 Answers0