diff --git a/config/_default/config.toml b/config/_default/config.toml index 7652d116e..040316b0c 100644 --- a/config/_default/config.toml +++ b/config/_default/config.toml @@ -1,5 +1,7 @@ baseURL = "https://kubesphere-v3.netlify.app" +enableRobotsTXT = true + [markup] [markup.tableOfContents] endLevel = 3 diff --git a/content/en/api/crd.md b/content/en/api/crd.md index 4cbf33361..696b33ddc 100644 --- a/content/en/api/crd.md +++ b/content/en/api/crd.md @@ -2,7 +2,7 @@ title: KubeSphere Api Documents description: KubeSphere Api Documents keywords: KubeSphere, KubeSphere Documents, Kubernetes - +disallow: true swaggerUrl: json/crd.json --- diff --git a/content/en/api/kubesphere.md b/content/en/api/kubesphere.md index d5ef99133..9893dd05a 100644 --- a/content/en/api/kubesphere.md +++ b/content/en/api/kubesphere.md @@ -2,6 +2,6 @@ title: KubeSphere Api Documents description: KubeSphere Api Documents keywords: KubeSphere, KubeSphere Documents, Kubernetes - +disallow: true swaggerUrl: json/kubesphere.json --- \ No newline at end of file diff --git a/content/en/contribution/request.md b/content/en/contribution/request.md index 1c0638364..09e80a978 100644 --- a/content/en/contribution/request.md +++ b/content/en/contribution/request.md @@ -1,7 +1,7 @@ --- title: "contribution request" layout: "request" - +disallow: true css: "scss/contribution.scss" section1: diff --git a/content/en/partner/request.md b/content/en/partner/request.md index c498dc62f..190c23f72 100644 --- a/content/en/partner/request.md +++ b/content/en/partner/request.md @@ -2,7 +2,7 @@ title: "partner request" layout: "request" - +disallow: true css: "scss/partner.scss" section1: diff --git a/content/zh/contribution/request.md b/content/zh/contribution/request.md index 1c0638364..09e80a978 100644 --- a/content/zh/contribution/request.md +++ b/content/zh/contribution/request.md @@ -1,7 +1,7 @@ --- title: "contribution request" layout: "request" - +disallow: true css: "scss/contribution.scss" section1: diff --git a/content/zh/partner/request.md b/content/zh/partner/request.md index c498dc62f..190c23f72 100644 --- a/content/zh/partner/request.md +++ b/content/zh/partner/request.md @@ -2,7 +2,7 @@ title: "partner request" layout: "request" - +disallow: true css: "scss/partner.scss" section1: diff --git a/layouts/robots.txt b/layouts/robots.txt new file mode 100644 index 000000000..6a6256f37 --- /dev/null +++ b/layouts/robots.txt @@ -0,0 +1,6 @@ +User-agent: * +{{ range .Pages }} +{{ if .Params.disallow }} +Disallow: {{ .RelPermalink }} +{{ end }} +{{ end }} \ No newline at end of file