From 97a1951fce19e8b81059285f22552b8e9e63a758 Mon Sep 17 00:00:00 2001 From: angelinekwan Date: Mon, 16 Jan 2023 11:26:27 +0200 Subject: [PATCH 1/3] Set custom canonical tag in base template --- _templates/base.html | 2 +- conf.py | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/_templates/base.html b/_templates/base.html index 71ef41d647..3fdfc23e84 100644 --- a/_templates/base.html +++ b/_templates/base.html @@ -2,8 +2,8 @@ {%- block extrahead %} {{ super() }} - + diff --git a/conf.py b/conf.py index 4a6f828cbc..5c50b4ff74 100644 --- a/conf.py +++ b/conf.py @@ -69,7 +69,8 @@ gitstamp_fmt = "%B %Y" # sitemap config -html_baseurl = 'https://docs.aiven.io' +# No base url as we don't want to have .html extension in the canonical url. Custom set canonical tag in _template/base.html instead. +html_baseurl = '' # Since we have `language='en'` set (further down) the URLs in the sitemap will # default to "{version}{lang}{link}", producing things like # https://docs.aiven.io/en/docs/platform/howto/create_authentication_token.html From aecab6088939957b53db3c30c319ad50bb21e2c6 Mon Sep 17 00:00:00 2001 From: angelinekwan Date: Mon, 16 Jan 2023 11:31:20 +0200 Subject: [PATCH 2/3] redirect remove.html as cloudflare page auto route matching --- _redirects | 34 +++++++++++++++++----------------- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/_redirects b/_redirects index 8a89d6595f..d7adcff4ff 100644 --- a/_redirects +++ b/_redirects @@ -11,42 +11,42 @@ /grafana /docs/products/grafana /api /docs/tools/api -/cli /docs/tools/cli.html +/cli /docs/tools/cli /terraform /docs/tools/terraform # Renamed/deleted files -/docs/products/flink/howto/real-time-alerting-solution-cli.html /docs/products/flink/howto/real-time-alerting-solution.html +/docs/products/flink/howto/real-time-alerting-solution-cli.html /docs/products/flink/howto/real-time-alerting-solution /docs/products/flink/howto/real-time-alerting-solution-cli /docs/products/flink/howto/real-time-alerting-solution -/docs/platform/howto/disable-user-2fa.html /docs/platform/howto/user-2fa.html +/docs/platform/howto/disable-user-2fa.html /docs/platform/howto/user-2fa /docs/platform/howto/disable-user-2fa /docs/platform/howto/user-2fa -/docs/tools/terraform/upgrade-provider-v1-v2.html /docs/tools/terraform/howto/upgrade-provider-v1-v2.html +/docs/tools/terraform/upgrade-provider-v1-v2.html /docs/tools/terraform/howto/upgrade-provider-v1-v2 /docs/tools/terraform/upgrade-provider-v1-v2 /docs/tools/terraform/howto/upgrade-provider-v1-v2 -/docs/products/mysql/howto/max-number-of-connections.html /docs/products/mysql/concepts/max-number-of-connections.html +/docs/products/mysql/howto/max-number-of-connections.html /docs/products/mysql/concepts/max-number-of-connections /docs/products/mysql/howto/max-number-of-connections /docs/products/mysql/concepts/max-number-of-connections -/docs/products/postgresql/reference/plan-iops.html /docs/products/postgresql/reference/resource-capability.html +/docs/products/postgresql/reference/plan-iops.html /docs/products/postgresql/reference/resource-capability /docs/products/postgresql/reference/plan-iops /docs/products/postgresql/reference/resource-capability -/docs/products/kafka/howto/enable-schema-registry-authorization.html /docs/products/kafka/karapace/howto/enable-schema-registry-authorization.html +/docs/products/kafka/howto/enable-schema-registry-authorization.html /docs/products/kafka/karapace/howto/enable-schema-registry-authorization /docs/products/kafka/howto/enable-schema-registry-authorization /docs/products/kafka/karapace/howto/enable-schema-registry-authorization -/docs/products/kafka/howto/manage-schema-registry-authorization.html /docs/products/kafka/karapace/howto/manage-schema-registry-authorization.html +/docs/products/kafka/howto/manage-schema-registry-authorization.html /docs/products/kafka/karapace/howto/manage-schema-registry-authorization /docs/products/kafka/howto/manage-schema-registry-authorization /docs/products/kafka/karapace/howto/manage-schema-registry-authorization -/docs/platform/howto/renaming-a-service.html /docs/platform/howto/rename-a-service.html +/docs/platform/howto/renaming-a-service.html /docs/platform/howto/rename-a-service /docs/platform/howto/renaming-a-service /docs/platform/howto/rename-a-service -/docs/platform/howto/recovering-a-deleted-service.html /docs/platform/howto/recover-a-deleted-service.html +/docs/platform/howto/recovering-a-deleted-service.html /docs/platform/howto/recover-a-deleted-service /docs/platform/howto/recovering-a-deleted-service /docs/platform/howto/recover-a-deleted-service -/docs/products/opensearch/howto/upgrade-to-opensearch-with-terraform.html /docs/tools/terraform/howto/upgrade-to-opensearch.html +/docs/products/opensearch/howto/upgrade-to-opensearch-with-terraform.html /docs/tools/terraform/howto/upgrade-to-opensearch /docs/products/opensearch/howto/upgrade-to-opensearch-with-terraform /docs/tools/terraform/howto/upgrade-to-opensearch /docs/platform/howto/migrate-services /docs/platform/howto/migrate-services-cloud-region /docs/products/clickhouse/howto/use-cli /docs/products/clickhouse/howto/connect-with-clickhouse-cli -/docs/products/clickhouse/howto/use-cli.html /docs/products/clickhouse/howto/connect-with-clickhouse-cli.html +/docs/products/clickhouse/howto/use-cli.html /docs/products/clickhouse/howto/connect-with-clickhouse-cli /docs/products/clickhouse/howto/grant-privilege /docs/products/clickhouse/howto/manage-users-roles -/docs/products/clickhouse/howto/grant-privilege.html /docs/products/clickhouse/howto/manage-users-roles.html +/docs/products/clickhouse/howto/grant-privilege.html /docs/products/clickhouse/howto/manage-users-roles /docs/products/clickhouse/howto/use-play /docs/products/clickhouse/howto/query-databases -/docs/products/clickhouse/howto/use-play.html /docs/products/clickhouse/howto/query-databases.html +/docs/products/clickhouse/howto/use-play.html /docs/products/clickhouse/howto/query-databases /docs/products/clickhouse/howto/use-query-editor /docs/products/clickhouse/howto/query-databases -/docs/products/clickhouse/howto/use-query-editor.html /docs/products/clickhouse/howto/query-databases.html +/docs/products/clickhouse/howto/use-query-editor.html /docs/products/clickhouse/howto/query-databases /docs/products/clickhouse/howto/add-service-users /docs/products/clickhouse/howto/manage-users-roles -/docs/products/clickhouse/howto/add-service-users.html /docs/products/clickhouse/howto/manage-users-roles.html -/docs/products/clickhouse/sample-dataset.html /docs/products/clickhouse/howto/load-dataset.html +/docs/products/clickhouse/howto/add-service-users.html /docs/products/clickhouse/howto/manage-users-roles +/docs/products/clickhouse/sample-dataset.html /docs/products/clickhouse/howto/load-dataset # Redirect from .index.html to specific page names for landing From 9eec2d1238016c10553f75374ae591daba0c2b72 Mon Sep 17 00:00:00 2001 From: angelinekwan Date: Mon, 16 Jan 2023 12:53:18 +0200 Subject: [PATCH 3/3] remove index in canonical for root folder page --- _templates/base.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/_templates/base.html b/_templates/base.html index 3fdfc23e84..35e32f5fb2 100644 --- a/_templates/base.html +++ b/_templates/base.html @@ -3,7 +3,7 @@ {%- block extrahead %} {{ super() }} - +