zoukankan      html  css  js  c++  java
  • kubectl explain IngressClass

    root@ubuntu:~/kubernetes-ingress/deployments/common# kubectl explain IngressClass
    KIND:     IngressClass
    VERSION:  networking.k8s.io/v1beta1
    
    DESCRIPTION:
         IngressClass represents the class of the Ingress, referenced by the Ingress
         Spec. The `ingressclass.kubernetes.io/is-default-class` annotation can be
         used to indicate that an IngressClass should be considered default. When a
         single IngressClass resource has this annotation set to true, new Ingress
         resources without a class specified will be assigned this default class.
    
    FIELDS:
       apiVersion   <string>
         APIVersion defines the versioned schema of this representation of an
         object. Servers should convert recognized schemas to the latest internal
         value, and may reject unrecognized values. More info:
         https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources
    
       kind <string>
         Kind is a string value representing the REST resource this object
         represents. Servers may infer this from the endpoint the client submits
         requests to. Cannot be updated. In CamelCase. More info:
         https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds
    
       metadata     <Object>
         Standard object's metadata. More info:
         https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#metadata
    
       spec <Object>
         Spec is the desired state of the IngressClass. More info:
         https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status
    
    root@ubuntu:~/kubernetes-ingress/deployments/common# kubectl explain IngressClass.spec
    KIND:     IngressClass
    VERSION:  networking.k8s.io/v1beta1
    
    RESOURCE: spec <Object>
    
    DESCRIPTION:
         Spec is the desired state of the IngressClass. More info:
         https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#spec-and-status
    
         IngressClassSpec provides information about the class of an Ingress.
    
    FIELDS:
       controller   <string>
         Controller refers to the name of the controller that should handle this
         class. This allows for different "flavors" that are controlled by the same
         controller. For example, you may have different Parameters for the same
         implementing controller. This should be specified as a domain-prefixed path
         no more than 250 characters in length, e.g. "acme.io/ingress-controller".
         This field is immutable.
    
       parameters   <Object>
         Parameters is a link to a custom resource containing additional
         configuration for the controller. This is optional if the controller does
         not require extra parameters.
    
    root@ubuntu:~/kubernetes-ingress/deployments/common# kubectl explain IngressClass.spec.controller
    KIND:     IngressClass
    VERSION:  networking.k8s.io/v1beta1
    
    FIELD:    controller <string>
    
    DESCRIPTION:
         Controller refers to the name of the controller that should handle this
         class. This allows for different "flavors" that are controlled by the same
         controller. For example, you may have different Parameters for the same
         implementing controller. This should be specified as a domain-prefixed path
         no more than 250 characters in length, e.g. "acme.io/ingress-controller".
         This field is immutable.
    root@ubuntu:~/kubernetes-ingress/deployments/common# kubectl create -f   ingress-k8s-class.yaml
    error: error validating "ingress-k8s-class.yaml": error validating data: ValidationError(IngressClass.spec): invalid type for io.k8s.api.networking.v1beta1.IngressClassSpec: got "string", expected "map"; if you choose to ignore these errors, turn validation off with --validate=false
    root@ubuntu:~/kubernetes-ingress/deployments/common# cat ingress-k8s-class.yaml
    apiVersion: networking.k8s.io/v1beta1
    kind: IngressClass
    metadata:
      name: nginx-k8s
      # annotations:
      #   ingressclass.kubernetes.io/is-default-class: "true"
    spec:
      controller:kubernetes.io/ingress-controller
    root@ubuntu:~/kubernetes-ingress/deployments/common# cat ingress-
    ingress-class.yaml      ingress-k8s-class.yaml  
    root@ubuntu:~/kubernetes-ingress/deployments/common# cat ingress-class.yaml 
    apiVersion: networking.k8s.io/v1beta1
    kind: IngressClass
    metadata:
      name: nginx-org
      # annotations:
      #   ingressclass.kubernetes.io/is-default-class: "true"
    spec:
      controller: nginx.org/ingress-controller
    root@ubuntu:~/kubernetes-ingress/deployments/common# kubectl get ingressclass
    NAME        CONTROLLER                         PARAMETERS   AGE
    nginx-k8s   kubernetes.io/ingress-controller   <none>       14s
    nginx-org   nginx.org/ingress-controller       <none>       4h30m
    root@ubuntu:~/kubernetes-ingress/deployments/common# 
  • 相关阅读:
    简单算法题20200815
    求图的连通子图的个数并保存每个子图的节点python
    java遍历树,并得到每条根到叶子节点的路径
    volatile 对于n=n+1,无效
    java重载(overload)和重写(override)
    对象的上转型对象
    (阿里巴巴笔试题)直线上安装水塔,水塔到直线上其它点的距离之和最小
    选择排序、树形排序、堆排序的java代码实现
    linux里面那些奇奇怪怪但是还没有解决的问题
    Linux使用free命令buff/cache过高
  • 原文地址:https://www.cnblogs.com/dream397/p/15191203.html
Copyright © 2011-2022 走看看