{"action":"created","issue":{"url":"https://api.github.com/repos/contao/contao/issues/148","repository_url":"https://api.github.com/repos/contao/contao","labels_url":"https://api.github.com/repos/contao/contao/issues/148/labels{/name}","comments_url":"https://api.github.com/repos/contao/contao/issues/148/comments","events_url":"https://api.github.com/repos/contao/contao/issues/148/events","html_url":"https://github.com/contao/contao/pull/148","id":375161842,"node_id":"MDExOlB1bGxSZXF1ZXN0MjI2NjcxODQ2","number":148,"title":"Automatically disable reverse proxy if request has surrogate capability","user":{"login":"Toflar","id":481937,"node_id":"MDQ6VXNlcjQ4MTkzNw==","avatar_url":"https://avatars2.githubusercontent.com/u/481937?v=4","gravatar_id":"","url":"https://api.github.com/users/Toflar","html_url":"https://github.com/Toflar","followers_url":"https://api.github.com/users/Toflar/followers","following_url":"https://api.github.com/users/Toflar/following{/other_user}","gists_url":"https://api.github.com/users/Toflar/gists{/gist_id}","starred_url":"https://api.github.com/users/Toflar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Toflar/subscriptions","organizations_url":"https://api.github.com/users/Toflar/orgs","repos_url":"https://api.github.com/users/Toflar/repos","events_url":"https://api.github.com/users/Toflar/events{/privacy}","received_events_url":"https://api.github.com/users/Toflar/received_events","type":"User","site_admin":false},"labels":[{"id":1028270366,"node_id":"MDU6TGFiZWwxMDI4MjcwMzY2","url":"https://api.github.com/repos/contao/contao/labels/feature","name":"feature","color":"3364b7","default":false}],"state":"open","locked":false,"assignee":{"login":"Toflar","id":481937,"node_id":"MDQ6VXNlcjQ4MTkzNw==","avatar_url":"https://avatars2.githubusercontent.com/u/481937?v=4","gravatar_id":"","url":"https://api.github.com/users/Toflar","html_url":"https://github.com/Toflar","followers_url":"https://api.github.com/users/Toflar/followers","following_url":"https://api.github.com/users/Toflar/following{/other_user}","gists_url":"https://api.github.com/users/Toflar/gists{/gist_id}","starred_url":"https://api.github.com/users/Toflar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Toflar/subscriptions","organizations_url":"https://api.github.com/users/Toflar/orgs","repos_url":"https://api.github.com/users/Toflar/repos","events_url":"https://api.github.com/users/Toflar/events{/privacy}","received_events_url":"https://api.github.com/users/Toflar/received_events","type":"User","site_admin":false},"assignees":[{"login":"Toflar","id":481937,"node_id":"MDQ6VXNlcjQ4MTkzNw==","avatar_url":"https://avatars2.githubusercontent.com/u/481937?v=4","gravatar_id":"","url":"https://api.github.com/users/Toflar","html_url":"https://github.com/Toflar","followers_url":"https://api.github.com/users/Toflar/followers","following_url":"https://api.github.com/users/Toflar/following{/other_user}","gists_url":"https://api.github.com/users/Toflar/gists{/gist_id}","starred_url":"https://api.github.com/users/Toflar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Toflar/subscriptions","organizations_url":"https://api.github.com/users/Toflar/orgs","repos_url":"https://api.github.com/users/Toflar/repos","events_url":"https://api.github.com/users/Toflar/events{/privacy}","received_events_url":"https://api.github.com/users/Toflar/received_events","type":"User","site_admin":false}],"milestone":{"url":"https://api.github.com/repos/contao/contao/milestones/2","html_url":"https://github.com/contao/contao/milestone/2","labels_url":"https://api.github.com/repos/contao/contao/milestones/2/labels","id":3583777,"node_id":"MDk6TWlsZXN0b25lMzU4Mzc3Nw==","number":2,"title":"4.7.0","description":"","creator":{"login":"leofeyer","id":1192057,"node_id":"MDQ6VXNlcjExOTIwNTc=","avatar_url":"https://avatars0.githubusercontent.com/u/1192057?v=4","gravatar_id":"","url":"https://api.github.com/users/leofeyer","html_url":"https://github.com/leofeyer","followers_url":"https://api.github.com/users/leofeyer/followers","following_url":"https://api.github.com/users/leofeyer/following{/other_user}","gists_url":"https://api.github.com/users/leofeyer/gists{/gist_id}","starred_url":"https://api.github.com/users/leofeyer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/leofeyer/subscriptions","organizations_url":"https://api.github.com/users/leofeyer/orgs","repos_url":"https://api.github.com/users/leofeyer/repos","events_url":"https://api.github.com/users/leofeyer/events{/privacy}","received_events_url":"https://api.github.com/users/leofeyer/received_events","type":"User","site_admin":false},"open_issues":26,"closed_issues":12,"state":"open","created_at":"2018-08-20T14:28:40Z","updated_at":"2018-11-14T13:23:13Z","due_on":null,"closed_at":null},"comments":6,"created_at":"2018-10-29T18:42:02Z","updated_at":"2018-11-15T06:14:13Z","closed_at":null,"author_association":"MEMBER","pull_request":{"url":"https://api.github.com/repos/contao/contao/pulls/148","html_url":"https://github.com/contao/contao/pull/148","diff_url":"https://github.com/contao/contao/pull/148.diff","patch_url":"https://github.com/contao/contao/pull/148.patch"},"body":"This would automatically disable the Symfony HttpCache if the request already has surrogate capability. One has to configure this anyway for Symfony to send ESI requests so there's no need for yet another variable.\r\n\r\nIf you want to have e.g. Varnish render the ESI tags, you have to add `Surrogate-Capability: ESI/1.0` to the request before it's passed on to Symfony,[ otherwise it will not understand that there's a proxy in front of it that does understand ESI](https://github.com/symfony/symfony/blob/master/src/Symfony/Component/HttpKernel/HttpCache/AbstractSurrogate.php#L54) and thus it will never render `<esi>` tags in the final output.\r\nSo you already have to configure your proxy to provide this information. There's no need to set yet another environment variable to tell Contao to disable `HttpCache`. We can use the same information here 😄 \r\n/cc @aschempp "},"comment":{"url":"https://api.github.com/repos/contao/contao/issues/comments/438929977","html_url":"https://github.com/contao/contao/pull/148#issuecomment-438929977","issue_url":"https://api.github.com/repos/contao/contao/issues/148","id":438929977,"node_id":"MDEyOklzc3VlQ29tbWVudDQzODkyOTk3Nw==","user":{"login":"Toflar","id":481937,"node_id":"MDQ6VXNlcjQ4MTkzNw==","avatar_url":"https://avatars2.githubusercontent.com/u/481937?v=4","gravatar_id":"","url":"https://api.github.com/users/Toflar","html_url":"https://github.com/Toflar","followers_url":"https://api.github.com/users/Toflar/followers","following_url":"https://api.github.com/users/Toflar/following{/other_user}","gists_url":"https://api.github.com/users/Toflar/gists{/gist_id}","starred_url":"https://api.github.com/users/Toflar/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Toflar/subscriptions","organizations_url":"https://api.github.com/users/Toflar/orgs","repos_url":"https://api.github.com/users/Toflar/repos","events_url":"https://api.github.com/users/Toflar/events{/privacy}","received_events_url":"https://api.github.com/users/Toflar/received_events","type":"User","site_admin":false},"created_at":"2018-11-15T06:14:13Z","updated_at":"2018-11-15T06:14:13Z","author_association":"MEMBER","body":"It is not. ESI support is required for Contao to work properly (e.g. for insert tags). So you have to also add ‚HTTP_SURROGATE_CAPABILITY=ESI/1.0‘ to the request anyway, otherwise it would have never generated any ESI tags. So until now you had to set both amyway."}}
{"actor":{"display_login":"Toflar"}}