Nuget server on IIS6 returns 404
Nuget server on IIS6 returns 404 when downloading package after upgrade
We updated our nuget server today and ran into a problem where regardless of package selected or whether it's through the nuget package manager or the nuget package explorer, the server returns 404 (File Not Found).
What was odd about this was that the packages exist and the feed was valid:
There are a couple of comments about this online e.g.: Codeplex Discussion 246387 but nothing helped. It took a while to work out that it was caused by a slight change to the way the nuget server makes it's calls. Comparing the IIS logs between the old and new version of nuget server, the previous version of nuget server would redirect the user directly to the nupkg file:
2011-04-21 08:47:46 W3SVC1759424837 192.168.1.1 GET /Packages/TheSiteDoctor.2.0.235.68.nupkg - 80 - 192.168.1.2 Package-Installer/1.2.20325.9034+(Microsoft+Windows+NT+6.1.7601+Service+Pack+1) 200 0 0
On the new one however, it passes the various requests through a new MVC route "download":
2011-09-01 11:31:16 W3SVC1759424837 192.168.1.1 GET /download/TheSiteDoctor/2.0.235.68 - 80 - 192.168.1.2 Package-Installer/1.2.20325.9034+(Microsoft+Windows+NT+6.1.7601+Service+Pack+1) 404 0 3
This is fine if your nuget server is running on IIS7, it will "just work". However if you're running IIS6 you'll need to make one additional change which is mapping all request through the aspnet_isapi.dll (a wildcard mapping). This is easy enough:
- 1. Open the site's properties in IIS6
- 2. Navigate to the "Home Directory" tab
- 3. Click the "Configuration" button:
- This will then open the "Application Configuration" window:
- Now you'll need to add the aspnet_isapi.dll mapping, the path of this will depend on the whether you're running Windox 64bit or not:
32bit Framework: c:\windows\microsoft.net\framework\v4.0.30319\aspnet_isapi.dll
64bit Framework: c:\windows\microsoft.net\framework64\v4.0.30319\aspnet_isapi.dll
Make sure you uncheck the "Verify that file exists" checkbox
Et voila your packages should all be working again.
Leave a comment if you need any additional help or it helped you.
Nuget server on IIS6 returns 404的更多相关文章
- .NET持续集成与自动化部署之路第二篇——使用NuGet.Server搭建公司内部的Nuget(包)管理器
使用NuGet.Server搭建公司内部的Nuget(包)管理器 前言 Nuget是一个.NET平台下的开源的项目,它是Visual Studio的扩展.在使用Visual Studio开发基 ...
- 搭建公司内部的NuGet Server
随着公司业务慢慢的拓展,项目便会越来越来多,很多项目会依赖其他项目DLL,比如一些底层的技术框架DLL引用,还有各业务系统的也有可能会有引用的可能. 项目多,交叉引用多,如果要是有一个DLL更新,那就 ...
- 分析nuget源码,用nuget + nuget.server实现winform程序的自动更新
源起 (个人理解)包管理最开始应该是从java平台下的maven开始吧,因为java的开发大多数是基于开源组件开发的,一个开源包在使用时很可能要去依赖其他的开源包,而且必须是特定的版本才可以.以往在找 ...
- Windows Server 2003 IIS6.0+PHP5(FastCGI)+MySQL5环境搭建教程
准备篇 一.环境说明: 操作系统:Windows Server 2003 SP2 32位 PHP版本:php 5.3.14(我用的php 5.3.10安装版) MySQL版本:MySQL5.5.25 ...
- org.codehaus.xfire.XFireRuntimeException: Could not invoke service.. Server returned error code = 404 for URI.. Check server logs for details
严重: Servlet.service() for servlet jsp threw exceptionorg.codehaus.xfire.XFireRuntimeException: Could ...
- Nuget Server 搭建
每个女人都有很多包包:其实男人也有,但只有会写程序的男人才有 -- 代码世界中的大"包"小"包".这些大包小包,有花钱买的,有从开源市场淘的,也有自己或同事亲手 ...
- nuget.server搭建及实际测试
1.背景 由于所做项目越来越多,会积累一些公用组件,而每个项目中组件引用中如果组件有更新或者新增为了方便需要一个专门的工具进行管理,那么nuget就是不错的选择. 2.安装nuget.server 这 ...
- Server response error code:404, error:{"ret":-1, "msg":"invalid appkey"}
Server response error code:404, error:{"ret":-1, "msg":"invalid appkey" ...
- [译]Nuget.Server
原文 NuGet.Server是一个包,可用于使一个ASP.NET应用host一个package feed . 使用VS创建一个新的空WEB应用,添加Nuget.Server包. 配置应用的Packa ...
随机推荐
- Elasticsearch分片&副本分配
集群索引中可能由多个分片构成,并且每个分片可以拥有多个副本,将一个单独的索引分为多个分片,可以处理不能在单一服务器上运行的 大型索引. 由于每个分片有多个副本,通过副本分配到多个服务器,可以提高查询的 ...
- AndroidStudio升到最新版本(3.1.2)之后
暂时发现的需要大家注意的地方 1.androidstudio3无法导入moudle? 例如:我写了一个简单的项目,需要导入一个第三方的moudle,我导入: 因为AS升级之后,没有突出颜色的变化(变黑 ...
- SGU 217. Two Cylinders
题意:给空间内两根圆柱,求轴线垂直相交时公共部分的体积. 暴力积分即可. ID: Date'n'Time: Name: Task: .Ext: Status: Time: Memory: 158937 ...
- Lr中脚本的迭代次数和场景运行时间的关系
Loadrunner中脚本的迭代次数和场景运行时间的关系 LR 的Vugen和controller中迭代是这样的: 当场景的持续时间为“运行至结束”时,以Vugen中设置的迭代次数为准 当场景的持续时 ...
- bzoj 1497 最小割
思路:最小割好难想啊,根本想不到.. S -> 用户群 = c[ i ] 基站 -> T = p[ i ] 用户群 -> a[ i ] = inf 用户群 -> b[ i ] ...
- java总结(二)(运算符)
算数和赋值运算符 1.变量类型溢出时候,会直接取反:出现x>x+1 2.知道a++和++a 3.知道a/0错误 a/0.0无穷大 字符串 1.知道栈区.堆区和方法区 2.知道new String ...
- 关于button标签会刷新页面的问题
当button标签在form表单里面时,这时点击button按钮会提交表单刷新页面. <form action=""> <button>点击</but ...
- codevs 2173 忠诚
2173 忠诚 时间限制: 1 s 空间限制: 32000 KB 题目等级 : 钻石 Diamond 题目描述 Description 老管家是一个聪明能干的人.他为财主工作了整整10年,财 ...
- [BZOJ4552][TJOI2016&&HEOI2016]排序(二分答案+线段树/线段树分裂与合并)
解法一:二分答案+线段树 首先我们知道,对于一个01序列排序,用线段树维护的话可以做到单次排序复杂度仅为log级别. 这道题只有一个询问,所以离线没有意义,而一个询问让我们很自然的想到二分答案.先二分 ...
- bzoj 1030
dp[i][j] 表示,在AC自动机中,从根节点开始,走了i条边,并且经过的点不包含危险节点,走到了j节点的路径数. 收获: 1.正难则反 2.一个字符串不包含给定pattern中的任何一个,则该字符 ...