Add doc-versions-lists and legacy-repos-deprecation shortcodes

Signed-off-by: Marko Mudrinić <mudrinic.mare@gmail.com>
This commit is contained in:
Marko Mudrinić 2023-10-17 16:20:08 +02:00
parent c6a1c0003c
commit c3ba6dc151
No known key found for this signature in database
3 changed files with 34 additions and 0 deletions

View File

@ -91,6 +91,9 @@ other = "I AM..."
[docs_label_users]
other = "Users"
[docs_page_versions]
other = "This %s is for Kubernetes %s. If you want to use a different Kubernetes version, please refer to the following pages instead:"
[docs_version_current]
other = "(this documentation)"
@ -279,6 +282,14 @@ other = "Thanks for the feedback. If you have a specific, answerable question ab
[layouts_docs_search_fetching]
other = "Fetching results..."
[legacy_repos_message]
other = """The legacy package repositories (`apt.kubernetes.io` and `yum.kubernetes.io`) have been
[deprecated and frozen starting from September 13, 2023](https://kubernetes.io/blog/2023/08/31/legacy-package-repository-deprecation/).
**Using the [new package repositories hosted at `pkgs.k8s.io`](https://kubernetes.io/blog/2023/08/15/pkgs-k8s-io-introduction/)
is strongly recommended and required in order to install Kubernetes versions released after September 13, 2023.**
The deprecated legacy repositories, and their contents, might be removed at any time in the future and without
a further notice period. The new package repositories provide downloads for Kubernetes versions starting with v1.24.0."""
[main_by]
other = "by"

View File

@ -0,0 +1,20 @@
{{ $versions := .Page.Param "versions" }}
{{ $thisPageRelUri := .Page.RelPermalink }}
{{ $thisPageTitle := .Page.Title }}
{{ $thisVersionArray := split (.Page.Param "version") "." }}
{{ $itemName := .Get 0 }}
<div class="version-list">
<p>
{{ printf (T "docs_page_versions") $itemName (delimit $thisVersionArray ".") }}
</p>
<ul>
{{ range $index, $version := $versions }}
{{ if ne .version ( delimit $thisVersionArray "." ) }}
<li>
<a href="{{ .url }}{{ $thisPageRelUri }}">{{ $thisPageTitle }} (Kubernetes {{ .version }})</a>
</li>
{{ end }}
{{ end }}
</ul>
</div>

View File

@ -0,0 +1,3 @@
<div class="alert alert-secondary callout note" role="alert">
<strong>{{ T "note" | safeHTML }}</strong> {{ T "legacy_repos_message" | markdownify }}
</div>