haskell – Web Scotty:提供静态文件时找不到文件
发布时间:2020-12-14 18:31:23 所属栏目:资源 来源:网络整理
导读:504 Gateway Time-out 504 Gateway Time-out nginx/1.12.2 解决方法 If I type ‘/index.html’ at the browser – it works. But it is wrong! I want it to be accessible via ‘/’ but not ‘/index.html’. 但这正是070??00中间件的用途!每当请求与策
504 Gateway Time-out解决方法
但这正是070??00中间件的用途!每当请求与策略匹配时(在本例中为./static/中的文件),它将被staticPolicy过滤.如果您不想要这种行为,请删除中间件.
因为middlware操作未设置以下命令的相对路径.您需要提供 main = scotty 3000 $do get "/" $file "./static/index.html" (编辑:李大同) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |