2017-08-22 2 views
0

KubernetesでTraefik v1.2.3からv1.3.6に更新しようとしています。私は私のTLS証明書を秘密からポッドの内部にマウントしました。 v1.2.3では、すべてが期待通りに機能します。私は私のv1.3.6の展開を(唯一の新しいドッキングウィンドウの画像である変更)を適用しようとすると、ポッドは、次のメッセージで起動に失敗:Traefikをv1.3.6にアップデートした後のTLS設定の作成中にエラーが発生しました。

defaultEntryPoints = ["http","https"] 
[entryPoints] 
    [entryPoints.http] 
    address = ":80" 
    [entryPoints.http.redirect] 
     entryPoint = "https" 
    [entryPoints.https] 
    address = ":443" 
     [entryPoints.https.tls] 
     [[entryPoints.https.tls.certificates]] 
     CertFile = "/ssl/wildcard.foo.mydomain.com.crt" 
     KeyFile = "/ssl/wildcard.foo.mydomain.com.key" 
     [[entryPoints.https.tls.certificates]] 
     CertFile = "/ssl/wildcard.mydomain.com.crt" 
     KeyFile = "/ssl/wildcard.mydomain.com.key" 
     [[entryPoints.https.tls.certificates]] 
     CertFile = "/ssl/wildcard.local.crt" 
     KeyFile = "/ssl/wildcard.local.key" 
[kubernetes] 
    labelselector = "expose=internal" 
:以下

time="2017-08-22T20:27:44Z" level=error msg="Error creating TLS config: tls: failed to find any PEM data in key input" 
time="2017-08-22T20:27:44Z" level=fatal msg="Error preparing server: tls: failed to find any PEM data in key input" 

私traefik.tomlファイルです

ポッドによって生成されるエラーの初期の印象は、秘密のキーが有効でないことです。しかし、私は秘密の内容をbase64で解読し、その値が私がローカルに保存した証明書ファイルの値と一致することを確認することができます。さらに、これらの事実が無効であれば、Traefikのどのバージョンでもこのエラーが発生することが予想されます。 Traefikの変更ログを調べると、SSLライブラリが更新されていることがわかりましたが、関連するPRはこれが唯一の暗号を追加し、これまでサポートされていたものを削除しなかったことを示しています。

:追加情報/ wの編集:--logLevel=DEBUGで実行

は(場合に、以下のフルで提供それは便利です)、この追加情報を提供しています。

[cluster-traefik-2693375319-w67hf] time="2017-08-22T21:41:19Z" level=debug msg="Global configuration loaded {"GraceTimeOut":10000000000,"Debug":false,"CheckNewVersion":true,"AccessLogsFile":"","TraefikLogsFile":"","LogLevel":"DEBUG","EntryPoints":{"http":{"Network":"","Address":":80","TLS":null,"Redirect":{"EntryPoint":"https","Regex":"","Replacement":""},"Auth":null,"Compress":false},"https":{"Network":"","Address":":443","TLS":{"MinVersion":"","CipherSuites":null,"Certificates":[{"CertFile":"/ssl/wildcard.foo.mydomain.com.crt","KeyFile":"/ssl/wildcard.foo.mydomain.com.key"},{"CertFile":"/ssl/wildcard.mydomain.com.crt","KeyFile":"/ssl/wildcard.mydomain.com.key"},{"CertFile":"/ssl/wildcard.local.crt","KeyFile":"/ssl/wildcard.local.key"}],"ClientCAFiles":null},"Redirect":null,"Auth":null,"Compress":false}},"Cluster":null,"Constraints":[],"ACME":null,"DefaultEntryPoints":["http","https"],"ProvidersThrottleDuration":2000000000,"MaxIdleConnsPerHost":200,"IdleTimeout":180000000000,"InsecureSkipVerify":false,"Retry":null,"HealthCheck":{"Interval":30000000000},"Docker":null,"File":null,"Web":{"Address":":8080","CertFile":"","KeyFile":"","ReadOnly":false,"Statistics":null,"Metrics":{"Prometheus":{"Buckets":[0.1,0.3,1.2,5]}},"Path":"","Auth":null},"Marathon":null,"Consul":null,"ConsulCatalog":null,"Etcd":null,"Zookeeper":null,"Boltdb":null,"Kubernetes":{"Watch":true,"Filename":"","Constraints":[],"Endpoint":"","Token":"","CertAuthFilePath":"","DisablePassHostHeaders":false,"Namespaces":null,"LabelSelector":"expose=internal"},"Mesos":null,"Eureka":null,"ECS":null,"Rancher":null,"DynamoDB":null}" 
[cluster-traefik-2693375319-w67hf] time="2017-08-22T21:41:19Z" level=info msg="Preparing server https &{Network: Address::443 TLS:0xc42060d800 Redirect:<nil> Auth:<nil> Compress:false}" 
[cluster-traefik-2693375319-w67hf] time="2017-08-22T21:41:19Z" level=error msg="Error creating TLS config: tls: failed to find any PEM data in key input" 
[cluster-traefik-2693375319-w67hf] time="2017-08-22T21:41:19Z" level=fatal msg="Error preparing server: tls: failed to find any PEM data in key input" 

答えて

0

この問題は、新しいvalidation logic in the crypto/tls library in Go 1.8であることが判明。彼らは証明書ブロックの末尾が-----であることを確認しています。証明書ファイルの秘密鍵が(ハイフンがありません)で終了しました。不足している文字を追加するとこの問題が修正されました

関連する問題