-
-
Notifications
You must be signed in to change notification settings - Fork 9.6k
UrlGenerator too eager to include port number in absolute urls #8561
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Im not able to reproduce this error with a similar setup. Have you got
in your vcl_recv? |
@Flask I tried adding your code to the beginning of vlc_recv and confirmed it gets called. But it didn't help. I wonder if this is an Apache issue after all. My Apache version is 2.2.22. |
If I dump
Still wondering if this is about Apache or Symfony |
relates to #3341 @TomiS read: http://symfony.com/doc/current/components/http_foundation/trusting_proxies.html |
@jakzal Thanks. After all it was about trusting proxies... I tried lots of stuff and finally noticed there was a flag Would it be ok to add a short notice about the config flag in documentation on the 'Trusting Proxies' page? I think the X-forwarded stuff could also be added to 'How to use Varnish to speed up my Website'. I guess no-one can really live without that config if one does the port configs the same way as in example. |
Closing this issue as invalid and swearing one of these days I'll report a real existing bug. :) |
@TomiS could you send a PR with a change you suggested to the https://github.com/symfony/symfony-docs? :) |
@jakzal Already did. See above . |
🍻 |
Hello everyone, Did you do any changes related to this topic? Actually I have the opposite problem: I want the port to appear when I generate my URL.. I am using the port 443 and the port is not shown in the absolute path.... Thanks. |
I have Apache listening port 8080 and Varnish listening port 80. It seems when I generate an absolute url with router, it adds port 8080 automatically. I'd like not to have any explicit ports in url even if I generate absolute urls
It seems to happen because of this code in Routing component's
UrlGenerator.php
Is this a bug or a feature or am I doing something wrong?
The text was updated successfully, but these errors were encountered: