Skip to content

website: fix duplicated origin in generated sitemap URLs - #4456

Open
HarshPopat23 wants to merge 1 commit into
kubeflow:masterfrom
HarshPopat23:fix-sitemap-duplicate-origin
Open

website: fix duplicated origin in generated sitemap URLs#4456
HarshPopat23 wants to merge 1 commit into
kubeflow:masterfrom
HarshPopat23:fix-sitemap-duplicate-origin

Conversation

@HarshPopat23

Copy link
Copy Markdown
Contributor

What this PR does / why we need it:

Fixes #4455

The production sitemap at https://www.kubeflow.org/sitemap.xml contained malformed URLs with a duplicated origin prefix (e.g. https://www.kubeflow.orghttps://www.kubeflow.org/...).

This happened because layouts/sitemap.xml prepended https://www.kubeflow.org to {{ .Permalink }}, even though Hugo already generates .Permalink as an absolute URL based on --baseURL during Netlify builds.

This PR:

  • Replaces <loc>https://www.kubeflow.org{{ .Permalink }}</loc> with <loc>{{ .Permalink }}</loc> in layouts/sitemap.xml.
  • Adds {{- if .Permalink }} check to prevent emitting empty <url> blocks.

Which issue(s) this PR fixes:

Fixes #4455

Signed-off-by: HarshPopat23 <musichk61@gmail.com>
@google-oss-prow

Copy link
Copy Markdown

Hi @HarshPopat23. Thanks for your PR.

I'm waiting for a kubeflow member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@google-oss-prow google-oss-prow Bot added size/XS area/website AREA: Website Styles/Hosting/Serving labels Aug 15, 2026
@google-oss-prow

Copy link
Copy Markdown

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please assign chasecadet for approval. For more information see the Kubernetes Code Review Process.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@github-actions

Copy link
Copy Markdown

🚫 This command cannot be processed. Only organization members or owners can use the commands.

@Arhell Arhell left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

/ok-to-test

@HarshPopat23

Copy link
Copy Markdown
Contributor Author

cc : @jaiakash @chasecadet @varodrig

@jaiakash jaiakash left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/website AREA: Website Styles/Hosting/Serving lgtm ok-to-test size/XS

Projects

None yet

Development

Successfully merging this pull request may close these issues.

bug(website): Fix duplicated origin in generated sitemap URLs

3 participants