我一直试图使用IIS部署django应用程序,但在执行了以下所有步骤之后,出现了错误
<handler> scriptProcessor could not be found in <fastCGI> application configuration我知道这个错误是由于脚本处理器值的路径不正确造成的,但是提到的值是正确的。请看下面的截图
启用wfastcgi的屏幕截图
Applied configuration changes to section "system.webServer/fastCgi" for "MACHINE/WEBROOT/APPHOST" at configuration commit path "MACHINE/WEBROOT/APPHOST"
""c:\program files\python39\python.exe"|"c:\program files\python39\lib\site-packages\wfastcgi.py"" can now be used as a FastCGI script processor下面是在www.root文件夹中的web.config文件中设置的值
<handlers>
<add name="Python FastCGI"
path="*"
verb="*"
modules="FastCgiModule"
scriptProcessor="c:\program files\python39\python.exe|c:\program files\python39\lib\site-packages\wfastcgi.py"
resourceType="Unspecified"
requireAccess="Script" />
</handlers>有人能帮我为什么要面对这个错误吗。
发布于 2021-05-13 16:37:33
问题终于解决了!
问题在于scriptProcessor密钥的值。scriptProcessor的路径有空间,这就是问题所在,错误被抛出。
最后,我不得不重新安装python,它的路径之间没有空格,就像下面这样,它正常工作。
scriptProcessor="c:\python39\python.exe|c:\python39\lib\site-
packages\wfastcgi.py"https://stackoverflow.com/questions/67510378
复制相似问题