Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

Document CRD categories set by crossplane

オープン
#1,122 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
3/5
見積もり時間
1〜2日
初心者へのやさしさ
58/100
issue の種類
ドキュメント
明瞭さ
おおむね明確
活発さ
静か
技術スタック
kubernetes
領域
documentation

調査の方向性

Crossplane ドキュメントの API セクションと、この issue にあるカテゴリの例および kubectl コマンドから始めます。Crossplane リソースに対してどのカテゴリが生成されるのかを追跡し、ドキュメントをどこに置くべきかを判断します。ユーザーが生成されたカテゴリを見つけ、無関係なカテゴリと区別し、カテゴリの変更が breaking changes であるかどうかを理解できれば完了です。

索引モデルが issue の本文から書いたものです。

説明

What's Missing?

As a crossplane user, it is hard to discover all categories that I can use in kubectl get <category> to interact with crossplane resources.

A web search site:https://docs.crossplane.io categories only returns the rendred XRD openapi schema at https://docs.crossplane.io/latest/api/

See also why it is currently hard for users to discover crd categories and consequently documentation would be useful https://github.com/kubernetes/website/issues/56279

As a workaround, users can try to reverse engineer the naming scheme that crossplane is using in categories assigned,

here is a sample command to show all categories in a cluster

kubectl get crds -o json | jq -r '
  # Extract all CRDs
  .items[]
  # Get the categories array from each CRD spec
  | .spec.names.categories[]?
  # Remove duplicates and sort alphabetically
' | sort -u | jq -R . | jq -s .

Here is the output on my cluster

["authzed",
  "azuread",
  "cert-manager",
  "cert-manager-acme",
  "claim",
  "composite",
  "crossplane",
  "external-secrets",
  "external-secrets-generators",
  "gateway-api",
  "gcp",
  "gitlab",
  "harbor",
  "helm",
  "http",
  "keycloak",
  "kpack",
  "kubernetes",
  "kyverno",
  "managed",
  "pkg",
  "pkgrev",
  "prometheus-operator",
  "provider",
  "providerconfig",
  "store",
  "strimzi",
  "terraform"
]

The crossplane categories not having a common prefix, it is hard to distinguish crossplane-related categories from other categories

here is a sample command to show all categories with nested related crds, which help filtering categories based on the related crd api groups (crossplane.io, and upbound.io)

kubectl get crds -o json | jq '
  # Create an array of category-CRD pairs
  [
    .items[] |
    # For each CRD, get its name and categories
    .spec.names.categories[]? as $category |
    {
      category: $category,
      crd: .metadata.name
    }
  ]
  # Group by category
  | group_by(.category)
  # Transform into desired format
  | map({
      category: .[0].category,
      crds: map(.crd) | sort
    })
  # Sort by category name
  | sort_by(.category)
'

Reverse engineering the category naming scheme, crossplane-core seems to assign categories named against the crossplane object model:

Crossplane concept category Assigned CRDs
managed resource managed all managed resources crds
claim claim + claim categories defined in xrd all claim crds
composite composite + composite categories defined in xrd ...
pkg pkg ...
pkgrev pkgrev ...
provider provider ...
provider-config provider-config ...
provider-family (e.g. gcp) crd on the given provider familly
crossplane all crds generated by crossplane + all core crossplane crds (ex xrd)

Since users may leverage categories to automate their interactions with crossplane, it is important that the generated categories be documented and that changes be considered a breaking change (e.g. implying semver bump for crossplane)

主要言語
SCSS
スター
60
フォーク
163
平均マージ
5日 6時間
マージ済み PR(30日)
1

環境構築

  • Dockerfile・Docker Compose ファイルなし
  • プルリクエストのテンプレートあり
  • コントリビューションガイドなし

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

crossplane/docs のほかの issue

crossplane/docs の issue をすべて見る

似ている issue

Documentation の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。