Namespace
apiVersion: v1
import "k8s.io/api/core/v1"
Namespace
Namespace 為 Names 提供了一個範圍。使用多個名稱空間是可選的。
apiVersion: v1
kind: Namespace
metadata (ObjectMeta)
標準物件的元資料。更多資訊:https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
spec (NamespaceSpec)
Spec 定義了 Namespace 的行為。更多資訊: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status
status (NamespaceStatus)
Status 描述了 Namespace 的當前狀態。更多資訊: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status
NamespaceSpec
NamespaceSpec 描述了 Namespace 的屬性。
finalizers ([]string)
原子性:在合併期間將被替換
Finalizers 是一個不透明的值列表,必須為空才能將物件永久地從儲存中刪除。更多資訊: https://kubernetes.club.tw/docs/tasks/administer-cluster/namespaces/
NamespaceStatus
NamespaceStatus 包含有關 Namespace 當前狀態的資訊。
conditions ([]NamespaceCondition)
補丁策略:按鍵
type
合併對映:合併時將保留鍵型別上的唯一值
表示 Namespace 當前狀態的最新可用觀察。
NamespaceCondition 包含有關名稱空間狀態的詳細資訊。
conditions.status (string),必需
條件的 status,可以是 True、False、Unknown 之一。
conditions.type (string),必需
名稱空間控制器條件的型別。
conditions.lastTransitionTime (Time)
條件上次從一種狀態轉換到另一種狀態的時間。
Time 是 time.Time 的一個包裝器,支援正確地編組到 YAML 和 JSON。提供了 time 包提供的許多工廠方法的包裝器。
conditions.message (string)
人類可讀的訊息,指示上次轉換的詳細資訊。
conditions.reason (string)
條件上次轉換的唯一、單字、駝峰式原因。
phase (string)
Phase 是名稱空間的當前生命週期階段。更多資訊: https://kubernetes.club.tw/docs/tasks/administer-cluster/namespaces/
NamespaceList
NamespaceList 是一個名稱空間列表。
apiVersion: v1
kind: NamespaceList
metadata (ListMeta)
標準列表元資料。更多資訊: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
items ([]Namespace), required
Items 是列表中的 Namespace 物件列表。更多資訊: https://kubernetes.club.tw/docs/concepts/overview/working-with-objects/namespaces/
操作
get
讀取指定的 Namespace
HTTP 請求
GET /api/v1/namespaces/{name}
引數
name (在路徑中): string,必填
Namespace 的名稱
pretty (在查詢中): string
響應
200 (Namespace): OK
401: 未授權
get
讀取指定的 Namespace 的狀態
HTTP 請求
GET /api/v1/namespaces/{name}/status
引數
name (在路徑中): string,必填
Namespace 的名稱
pretty (在查詢中): string
響應
200 (Namespace): OK
401: 未授權
list
列出或監視 Namespace 型別的物件
HTTP 請求
GET /api/v1/namespaces
引數
allowWatchBookmarks (在查詢中): boolean
continue (在查詢中): string
fieldSelector (在查詢中): string
labelSelector (在查詢中): string
limit (在查詢中): integer
pretty (在查詢中): string
resourceVersion (在查詢中): string
resourceVersionMatch (在查詢中): string
sendInitialEvents (在查詢中): boolean
timeoutSeconds (在查詢中): integer
watch (在查詢中): boolean
響應
200 (NamespaceList): OK
401: 未授權
create
建立一個 Namespace
HTTP 請求
POST /api/v1/namespaces
引數
body: Namespace, required
dryRun (在查詢中): string
fieldManager (在查詢中): string
fieldValidation (在查詢中): string
pretty (在查詢中): string
響應
200 (Namespace): OK
201 (Namespace): Created
202 (Namespace): Accepted
401: 未授權
update
替換指定的 Namespace
HTTP 請求
PUT /api/v1/namespaces/{name}
引數
name (在路徑中): string,必填
Namespace 的名稱
body: Namespace, required
dryRun (在查詢中): string
fieldManager (在查詢中): string
fieldValidation (在查詢中): string
pretty (在查詢中): string
響應
200 (Namespace): OK
201 (Namespace): Created
401: 未授權
update
替換指定的 Namespace 的 finalize
HTTP 請求
PUT /api/v1/namespaces/{name}/finalize
引數
name (在路徑中): string,必填
Namespace 的名稱
body: Namespace, required
dryRun (在查詢中): string
fieldManager (在查詢中): string
fieldValidation (在查詢中): string
pretty (在查詢中): string
響應
200 (Namespace): OK
201 (Namespace): Created
401: 未授權
update
替換指定的 Namespace 的狀態
HTTP 請求
PUT /api/v1/namespaces/{name}/status
引數
name (在路徑中): string,必填
Namespace 的名稱
body: Namespace, required
dryRun (在查詢中): string
fieldManager (在查詢中): string
fieldValidation (在查詢中): string
pretty (在查詢中): string
響應
200 (Namespace): OK
201 (Namespace): Created
401: 未授權
patch
部分更新指定的 Namespace
HTTP 請求
PATCH /api/v1/namespaces/{name}
引數
name (在路徑中): string,必填
Namespace 的名稱
body: Patch,必需
dryRun (在查詢中): string
fieldManager (在查詢中): string
fieldValidation (在查詢中): string
force (在查詢中): boolean
pretty (在查詢中): string
響應
200 (Namespace): OK
201 (Namespace): Created
401: 未授權
patch
部分更新指定的 Namespace 的狀態
HTTP 請求
PATCH /api/v1/namespaces/{name}/status
引數
name (在路徑中): string,必填
Namespace 的名稱
body: Patch,必需
dryRun (在查詢中): string
fieldManager (在查詢中): string
fieldValidation (在查詢中): string
force (在查詢中): boolean
pretty (在查詢中): string
響應
200 (Namespace): OK
201 (Namespace): Created
401: 未授權
delete
刪除一個 Namespace
HTTP 請求
DELETE /api/v1/namespaces/{name}
引數
name (在路徑中): string,必填
Namespace 的名稱
body: DeleteOptions
dryRun (在查詢中): string
gracePeriodSeconds (在查詢中): integer
ignoreStoreReadErrorWithClusterBreakingPotential (在查詢中): boolean
pretty (在查詢中): string
propagationPolicy (在查詢中): string
響應
200 (Status): OK
202 (Status): 已接受
401: 未授權
本頁面是自動生成的。
如果你打算報告此頁面存在的問題,請在問題描述中提及此頁面是自動生成的。修復可能需要在 Kubernetes 專案的其他地方進行。