Skip to content
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

[IMP] use relative addresses to self in links #90

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

hbrunn
Copy link

@hbrunn hbrunn commented Dec 9, 2015

No description provided.

</t>
<li t-if="bu['state'] in ['done','running'] and bu_index==0">
<a href="#" class="runbot-rebuild" t-att-data-runbot-build="bu['id']">Rebuild <i class="fa fa-refresh"/></a>
</li>
<li t-if="bu['state']!='testing' and bu['state']!='pending'" class="divider"></li>
<li><a t-attf-href="/runbot/build/{{bu['id']}}">Logs <i class="fa fa-file-text-o"/></a></li>
<li t-if="bu['host']"><a t-attf-href="http://{{bu['host']}}/runbot/static/build/#{bu['real_dest']}/logs/job_10_test_base.txt">Full base logs <i class="fa fa-file-text-o"/></a></li>
<li t-if="bu['host']"><a t-attf-href="http://{{bu['host']}}/runbot/static/build/#{bu['real_dest']}/logs/job_20_test_all.txt">Full all logs <i class="fa fa-file-text-o"/></a></li>
<li t-if="bu['host']"><a t-attf-href="/runbot/static/build/#{bu['real_dest']}/logs/job_10_test_base.txt">Full base logs <i class="fa fa-file-text-o"/></a></li>
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Was there a reasoning behind only using the path in the href? IMO this and the below few hrefs should use the protocol relative domain as well, like the above ones.

//{{bu['domain']}}/runbot/static/build/#{bu['real_dest']}/logs/job_10_test_base.txt

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the reasoning was that this is a link to runbot's frontend, and depending on your configuration, bu['host'] gives you the wrong value: https://github.com/odoo/odoo-extra/blob/master/runbot/runbot.py#L1068 - this is needed for load balancing (I guess), but here, the link must go to the frontend. I think this is a generic issue that doesn't bite much more people because the fqdn coincides with the frontend domain name very often.

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah this makes sense, thanks for the elaboration @hbrunn

@lasley
Copy link

lasley commented Jul 11, 2016

👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants