{"comment":{"url":"https://api.github.com/repos/purescript/pursuit/comments/14577103","html_url":"https://github.com/purescript/pursuit/commit/5da82dcfad148fbe44db2773921489d244655733#commitcomment-14577103","id":14577103,"user":{"login":"hdgarrood","id":1270186,"avatar_url":"https://avatars.githubusercontent.com/u/1270186?v=3","gravatar_id":"","url":"https://api.github.com/users/hdgarrood","html_url":"https://github.com/hdgarrood","followers_url":"https://api.github.com/users/hdgarrood/followers","following_url":"https://api.github.com/users/hdgarrood/following{/other_user}","gists_url":"https://api.github.com/users/hdgarrood/gists{/gist_id}","starred_url":"https://api.github.com/users/hdgarrood/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hdgarrood/subscriptions","organizations_url":"https://api.github.com/users/hdgarrood/orgs","repos_url":"https://api.github.com/users/hdgarrood/repos","events_url":"https://api.github.com/users/hdgarrood/events{/privacy}","received_events_url":"https://api.github.com/users/hdgarrood/received_events","type":"User","site_admin":false},"position":null,"line":null,"path":"","commit_id":"5da82dcfad148fbe44db2773921489d244655733","created_at":"2015-11-24T01:54:42Z","updated_at":"2015-11-24T01:54:42Z","body":"@paf31 this commit improves the situation somewhat - now at least you get the content type ask for (if the resource is available in that content type).\r\n\r\nThe problem now is actually quite awkward. Suppose someone tries to get some resource with text/html in the accept header, but only a json version of that resource exists on the disk. There are now two possibilities: this resource is available as html, but nobody has asked for it yet, and so we should use the Yesod backend, or this resource is not available as html, and we should serve the cached JSON.\r\n\r\nI can't see how nginx could be able to tell the difference between these two situations.\r\n\r\nThe above config always assumes we're in case 1 and proxies to the Yesod backend every time if the exact requested content type does not exist. The only problem with this I'm aware of is that it makes the caching a bit less effective, as whenever this happens, it will skip the cache.\r\n\r\nAlso the `if ($request_method != GET)` stuff is for a separate issue, see the comments in the config file."}}