Skip to content

Commit

Permalink
docs: better compatibility matrix (#5842)
Browse files Browse the repository at this point in the history
  • Loading branch information
erezzarum authored Mar 13, 2024
1 parent bc62192 commit c2016b2
Show file tree
Hide file tree
Showing 7 changed files with 20 additions and 21 deletions.
4 changes: 2 additions & 2 deletions tools/kompat/pkg/kompat/kompat.go
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ func (k Kompat) Markdown(_ ...Options) string {
data := []string{k.Name}
for _, c := range k.Compatibility {
if c.MaxK8sVersion == "" || c.MinK8sVersion == c.MaxK8sVersion {
headers = append(headers, fmt.Sprintf("`%s`+", c.MinK8sVersion))
headers = append(headers, fmt.Sprintf("\\>= `%s`", c.MinK8sVersion))
} else {
headers = append(headers, fmt.Sprintf("`%s` - `%s`", c.MinK8sVersion, c.MaxK8sVersion))
}
Expand Down Expand Up @@ -365,7 +365,7 @@ func semverRange(semvers []string, allSemvers ...string) string {
allSems := allSemvers
sortSemvers(allSems)
if allSems[len(allSems)-1] == semvers[len(semvers)-1] {
return fmt.Sprintf("%s+", semvers[0])
return fmt.Sprintf("\\>= %s", strings.ReplaceAll(semvers[0], ".x", ""))
}
}
return fmt.Sprintf("%s - %s", semvers[0], semvers[len(semvers)-1])
Expand Down
6 changes: 3 additions & 3 deletions website/content/en/docs/upgrading/compatibility.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@ Before you begin upgrading Karpenter, consider Karpenter compatibility issues re

[comment]: <> (the content below is generated from hack/docs/compataiblitymetrix_gen_docs.go)

| KUBERNETES | 1.23 | 1.24 | 1.25 | 1.26 | 1.27 | 1.28 | 1.29 |
|------------|---------|---------|---------|---------|---------|---------|---------|
| karpenter | 0.21.x+ | 0.21.x+ | 0.25.x+ | 0.28.x+ | 0.28.x+ | 0.31.x+ | 0.34.0+ |
| KUBERNETES | 1.23 | 1.24 | 1.25 | 1.26 | 1.27 | 1.28 | 1.29 |
|------------|----------|----------|----------|----------|----------|----------|------------|
| karpenter | \>= 0.21 | \>= 0.21 | \>= 0.25 | \>= 0.28 | \>= 0.28 | \>= 0.31 | \>= 0.34.0 |

[comment]: <> (end docs generated content from hack/docs/compataiblitymetrix_gen_docs.go)

Expand Down
6 changes: 3 additions & 3 deletions website/content/en/preview/upgrading/compatibility.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@ Before you begin upgrading Karpenter, consider Karpenter compatibility issues re

[comment]: <> (the content below is generated from hack/docs/compataiblitymetrix_gen_docs.go)

| KUBERNETES | 1.23 | 1.24 | 1.25 | 1.26 | 1.27 | 1.28 | 1.29 |
|------------|---------|---------|---------|---------|---------|---------|---------|
| karpenter | 0.21.x+ | 0.21.x+ | 0.25.x+ | 0.28.x+ | 0.28.x+ | 0.31.x+ | 0.34.0+ |
| KUBERNETES | 1.23 | 1.24 | 1.25 | 1.26 | 1.27 | 1.28 | 1.29 |
|------------|----------|----------|----------|----------|----------|----------|------------|
| karpenter | \>= 0.21 | \>= 0.21 | \>= 0.25 | \>= 0.28 | \>= 0.28 | \>= 0.31 | \>= 0.34.0 |

[comment]: <> (end docs generated content from hack/docs/compataiblitymetrix_gen_docs.go)

Expand Down
6 changes: 3 additions & 3 deletions website/content/en/v0.32/upgrading/compatibility.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@ Before you begin upgrading Karpenter, consider Karpenter compatibility issues re

[comment]: <> (the content below is generated from hack/docs/compataiblitymetrix_gen_docs.go)

| KUBERNETES | 1.23 | 1.24 | 1.25 | 1.26 | 1.27 | 1.28 |
|------------|---------|---------|---------|---------|---------|---------|
| karpenter | 0.21.x+ | 0.21.x+ | 0.25.x+ | 0.28.x+ | 0.28.x+ | 0.31.x+ |
| KUBERNETES | 1.23 | 1.24 | 1.25 | 1.26 | 1.27 | 1.28 | 1.29 |
|------------|----------|----------|----------|----------|----------|----------|------------|
| karpenter | \>= 0.21 | \>= 0.21 | \>= 0.25 | \>= 0.28 | \>= 0.28 | \>= 0.31 | \>= 0.34.0 |

[comment]: <> (end docs generated content from hack/docs/compataiblitymetrix_gen_docs.go)

Expand Down
6 changes: 3 additions & 3 deletions website/content/en/v0.33/upgrading/compatibility.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@ Before you begin upgrading Karpenter, consider Karpenter compatibility issues re

[comment]: <> (the content below is generated from hack/docs/compataiblitymetrix_gen_docs.go)

| KUBERNETES | 1.23 | 1.24 | 1.25 | 1.26 | 1.27 | 1.28 |
|------------|---------|---------|---------|---------|---------|---------|
| karpenter | 0.21.x+ | 0.21.x+ | 0.25.x+ | 0.28.x+ | 0.28.x+ | 0.31.x+ |
| KUBERNETES | 1.23 | 1.24 | 1.25 | 1.26 | 1.27 | 1.28 | 1.29 |
|------------|----------|----------|----------|----------|----------|----------|------------|
| karpenter | \>= 0.21 | \>= 0.21 | \>= 0.25 | \>= 0.28 | \>= 0.28 | \>= 0.31 | \>= 0.34.0 |

[comment]: <> (end docs generated content from hack/docs/compataiblitymetrix_gen_docs.go)

Expand Down
7 changes: 3 additions & 4 deletions website/content/en/v0.34/upgrading/compatibility.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@ Before you begin upgrading Karpenter, consider Karpenter compatibility issues re

[comment]: <> (the content below is generated from hack/docs/compataiblitymetrix_gen_docs.go)

| KUBERNETES | 1.23 | 1.24 | 1.25 | 1.26 | 1.27 | 1.28 | 1.29 |
|------------|---------|---------|---------|---------|---------|---------|---------|
| karpenter | 0.21.x+ | 0.21.x+ | 0.25.x+ | 0.28.x+ | 0.28.x+ | 0.31.x+ | 0.34.x+ |
| KUBERNETES | 1.23 | 1.24 | 1.25 | 1.26 | 1.27 | 1.28 | 1.29 |
|------------|----------|----------|----------|----------|----------|----------|------------|
| karpenter | \>= 0.21 | \>= 0.21 | \>= 0.25 | \>= 0.28 | \>= 0.28 | \>= 0.31 | \>= 0.34.0 |

[comment]: <> (end docs generated content from hack/docs/compataiblitymetrix_gen_docs.go)

Expand Down Expand Up @@ -103,4 +103,3 @@ aws ecr get-login-password --region {{< param "snapshot_repo.region" >}} | docke
{{% alert title="Note" color="warning" %}}
Snapshot releases are suitable for testing, and troubleshooting but they should not be used in production environments. Snapshot releases are ephemeral and will be removed 90 days after they were published.
{{% /alert %}}

6 changes: 3 additions & 3 deletions website/content/en/v0.35/upgrading/compatibility.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@ Before you begin upgrading Karpenter, consider Karpenter compatibility issues re

[comment]: <> (the content below is generated from hack/docs/compataiblitymetrix_gen_docs.go)

| KUBERNETES | 1.23 | 1.24 | 1.25 | 1.26 | 1.27 | 1.28 | 1.29 |
|------------|---------|---------|---------|---------|---------|---------|---------|
| karpenter | 0.21.x+ | 0.21.x+ | 0.25.x+ | 0.28.x+ | 0.28.x+ | 0.31.x+ | 0.34.0+ |
| KUBERNETES | 1.23 | 1.24 | 1.25 | 1.26 | 1.27 | 1.28 | 1.29 |
|------------|----------|----------|----------|----------|----------|----------|------------|
| karpenter | \>= 0.21 | \>= 0.21 | \>= 0.25 | \>= 0.28 | \>= 0.28 | \>= 0.31 | \>= 0.34.0 |

[comment]: <> (end docs generated content from hack/docs/compataiblitymetrix_gen_docs.go)

Expand Down

0 comments on commit c2016b2

Please sign in to comment.