2017-05-19 3 views
0

私はKubernetesクラスター(v1.5.7)にヘルム(V2.4.1)ティラーをインストールしようとしています。これはインターネット以外の環境でも実行できる必要があるため、Tiller展開のマニフェストをhelm init --dry-run --debugから取得したいと考えています。しかし、マニフェストをtiller.yamlというファイルにコピーしてからkubectl create -f tiller.yamlを実行すると、次のような検証エラーが発生します。ファイルに何が問題なのですか?このKubernetesマニフェスト検証が失敗する原因は何ですか?

error validating "tiller.yaml": error validating data: [found invalid field labels for v1beta1.Deployment, found invalid field name for v1beta1.Deployment, found invalid field namespace for v1beta1.Deployment, found invalid field Spec for v1beta1.Deployment, found invalid field Status for v1beta1.Deployment, found invalid field creationTimestamp for v1beta1.Deployment]; if you choose to ignore these errors, turn validation off with --validate=false 

tiller.yaml:

apiVersion: extensions/v1beta1 
kind: Deployment 
Spec: 
    MinReadySeconds: 0 
    Paused: false 
    ProgressDeadlineSeconds: null 
    Replicas: 1 
    RevisionHistoryLimit: null 
    RollbackTo: null 
    Selector: null 
    Strategy: 
    RollingUpdate: null 
    Type: "" 
    Template: 
    Spec: 
     ActiveDeadlineSeconds: null 
     Affinity: null 
     AutomountServiceAccountToken: null 
     Containers: 
     - Args: null 
     Command: null 
     Env: 
     - Name: TILLER_NAMESPACE 
      Value: kube-system 
      ValueFrom: null 
     EnvFrom: null 
     Image: gcr.io/kubernetes-helm/tiller:v2.4.1 
     ImagePullPolicy: IfNotPresent 
     Lifecycle: null 
     LivenessProbe: 
      Exec: null 
      FailureThreshold: 0 
      HTTPGet: 
      HTTPHeaders: null 
      Host: "" 
      Path: /liveness 
      Port: 44135 
      Scheme: "" 
      InitialDelaySeconds: 1 
      PeriodSeconds: 0 
      SuccessThreshold: 0 
      TCPSocket: null 
      TimeoutSeconds: 1 
     Name: tiller 
     Ports: 
     - ContainerPort: 44134 
      HostIP: "" 
      HostPort: 0 
      Name: tiller 
      Protocol: "" 
     ReadinessProbe: 
      Exec: null 
      FailureThreshold: 0 
      HTTPGet: 
      HTTPHeaders: null 
      Host: "" 
      Path: /readiness 
      Port: 44135 
      Scheme: "" 
      InitialDelaySeconds: 1 
      PeriodSeconds: 0 
      SuccessThreshold: 0 
      TCPSocket: null 
      TimeoutSeconds: 1 
     Resources: 
      Limits: null 
      Requests: null 
     SecurityContext: null 
     Stdin: false 
     StdinOnce: false 
     TTY: false 
     TerminationMessagePath: "" 
     TerminationMessagePolicy: "" 
     VolumeMounts: null 
     WorkingDir: "" 
     DNSPolicy: "" 
     Hostname: "" 
     ImagePullSecrets: null 
     InitContainers: null 
     NodeName: "" 
     NodeSelector: null 
     RestartPolicy: "" 
     SchedulerName: "" 
     SecurityContext: 
     FSGroup: null 
     HostIPC: false 
     HostNetwork: false 
     HostPID: false 
     RunAsNonRoot: null 
     RunAsUser: null 
     SELinuxOptions: null 
     SupplementalGroups: null 
     ServiceAccountName: "" 
     Subdomain: "" 
     TerminationGracePeriodSeconds: null 
     Tolerations: null 
     Volumes: null 
    creationTimestamp: null 
    labels: 
     app: helm 
     name: tiller 
Status: 
    AvailableReplicas: 0 
    Conditions: null 
    ObservedGeneration: 0 
    ReadyReplicas: 0 
    Replicas: 0 
    UnavailableReplicas: 0 
    UpdatedReplicas: 0 
creationTimestamp: null 
labels: 
    app: helm 
    name: tiller 
name: tiller-deploy 
namespace: kube-system 
--- 
apiVersion: v1 
kind: Service 
Spec: 
    ClusterIP: "" 
    ExternalIPs: null 
    ExternalName: "" 
    LoadBalancerIP: "" 
    LoadBalancerSourceRanges: null 
    Ports: 
    - Name: tiller 
    NodePort: 0 
    Port: 44134 
    Protocol: "" 
    TargetPort: tiller 
    Selector: 
    app: helm 
    name: tiller 
    SessionAffinity: "" 
    Type: ClusterIP 
Status: 
    LoadBalancer: 
    Ingress: null 
creationTimestamp: null 
labels: 
    app: helm 
    name: tiller 
name: tiller-deploy 
namespace: kube-system 

答えて

1

あなたのすべての属性は小文字で開始する必要があり、かつcreationTimestamp /ラベル/などは、すべての "メタデータ" スタンザ内に表示されます。このマニフェストはどのように形成されましたか?

+0

これは 'helm init --dry-run --debug'を実行して作成されました。 – John

+0

ヘルムはおそらく、APIの構造体の内部バージョンをシリアライズしています。これはhttps://github.com/kubernetes/helm/issues/2181#issuecomment-290810996で報告され、https://github.com/kubernetes/helm/pull/2248で修正されたようです –

関連する問題