jekyll / jekyll-seo-tag

A Jekyll plugin to add metadata tags for search engines and social networks to better index and display your site's content.
https://jekyll.github.io/jekyll-seo-tag
MIT License
1.66k stars 294 forks source link

Duplicate hostname in canonical url #508

Closed mnlipp closed 4 months ago

mnlipp commented 4 months ago

I have a rather simple documentation project. When I build it locally, everything looks fine. I get canonical_urls like this <link rel="canonical" href="[http://localhost:4000/](view-source:http://localhost:4000/)" />. The built in github, however, results in canonical_urls with a duplicate hostname such as <link rel="canonical" href="[https://jdrupes.org/jdrupes.org/](view-source:https://jdrupes.org/jdrupes.org/)" />.

I have found the template and from this it looks like seo_tag.canonical_url has been set to the wrong value. But I have no idea what could cause this. IMHO It should be set from site.url and I have specified this.

mnlipp commented 4 months ago

Cause was wrong jekyll invocation in default actions template.