-
Notifications
You must be signed in to change notification settings - Fork 218
TLS: converge asset naming of SH and non-SH etcd #621
Conversation
d8aaeae
to
f2f768b
Compare
Manually verified recovery case too. |
@xiang90 @diegs @aaronlevy |
coreosbot run e2e Seems flake:
|
coreosbot run e2e |
@aaronlevy @diegs Can you approve this? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Somme comments based on what you wrote in #611 (comment)
Am I misunderstanding the distinction between client-ca and server-ca?
@@ -21,10 +21,10 @@ coreos: | |||
Environment="ETCD_LISTEN_PEER_URLS=https://$private_ipv4:2380" | |||
Environment="ETCD_INITIAL_CLUSTER={{ETCD_INITIAL_CLUSTER}}" | |||
Environment="ETCD_SSL_DIR=/etc/etcd/tls" | |||
Environment="ETCD_TRUSTED_CA_FILE=/etc/ssl/certs/etcd-ca.crt" | |||
Environment="ETCD_TRUSTED_CA_FILE=/etc/ssl/certs/etcd-client-ca.crt" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
etcd-server-ca.rt?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(and the below should be etcd-server.crt
and etcd-server.key
Environment="ETCD_PEER_TRUSTED_CA_FILE=/etc/ssl/certs/etcd-ca.crt" | ||
Environment="ETCD_PEER_CERT_FILE=/etc/ssl/certs/etcd-peer.crt" | ||
Environment="ETCD_PEER_KEY_FILE=/etc/ssl/certs/etcd-peer.key" | ||
Environment="ETCD_PEER_TRUSTED_CA_FILE=/etc/ssl/certs/etcd-client-ca.crt" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
shouldn't this be peer-ca.crt
?
Environment="ETCD_PEER_TRUSTED_CA_FILE=/etc/ssl/certs/etcd-ca.crt" | ||
Environment="ETCD_PEER_CERT_FILE=/etc/ssl/certs/etcd-peer.crt" | ||
Environment="ETCD_PEER_KEY_FILE=/etc/ssl/certs/etcd-peer.key" | ||
Environment="ETCD_PEER_TRUSTED_CA_FILE=/etc/ssl/certs/etcd-client-ca.crt" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
etcd-peer-ca.crt?
hack/quickstart/init-master.sh
Outdated
Environment="ETCD_PEER_TRUSTED_CA_FILE=/etc/ssl/certs/etcd-ca.crt" | ||
Environment="ETCD_PEER_CERT_FILE=/etc/ssl/certs/etcd-peer.crt" | ||
Environment="ETCD_PEER_KEY_FILE=/etc/ssl/certs/etcd-peer.key" | ||
Environment="ETCD_PEER_TRUSTED_CA_FILE=/etc/ssl/certs/etcd-client-ca.crt" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
peer-ca.crt?
@@ -12,11 +12,11 @@ | |||
Environment="ETCD_LISTEN_CLIENT_URLS=https://0.0.0.0:2379" | |||
Environment="ETCD_LISTEN_PEER_URLS=https://0.0.0.0:2380" | |||
Environment="ETCD_SSL_DIR=/etc/etcd/tls" | |||
Environment="ETCD_TRUSTED_CA_FILE=/etc/ssl/certs/etcd-ca.crt" | |||
Environment="ETCD_TRUSTED_CA_FILE=/etc/ssl/certs/etcd-client-ca.crt" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
etcd-server-ca.crt?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(and the two lines below)
@diegs
|
@hongchaodeng couldn't the non-self-hosted code path in (Discussed in 2 comments at #611 (comment), I know it's a long thread so thanks for helping to clean all this up) |
@diegs |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd really just rather get this right in this PR. It's only a few more lines, and then it's done. If we punt to another PR we are going to change some of the exact same lines again.
@@ -139,7 +139,7 @@ func newEtcdTLSAssets(etcdCACert, etcdClientCert *x509.Certificate, etcdClientKe | |||
} | |||
|
|||
assets = append(assets, []Asset{ | |||
{Name: AssetPathEtcdCA, Data: tlsutil.EncodeCertificatePEM(etcdCACert)}, | |||
{Name: AssetPathEtcdClientCA, Data: tlsutil.EncodeCertificatePEM(etcdCACert)}, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please add AssetPathEtcdServer[CA,Key,Cert]
here.
Please add AssetPathEtcdPeerCA
on line 136 above.
@@ -21,10 +21,10 @@ coreos: | |||
Environment="ETCD_LISTEN_PEER_URLS=https://$private_ipv4:2380" | |||
Environment="ETCD_INITIAL_CLUSTER={{ETCD_INITIAL_CLUSTER}}" | |||
Environment="ETCD_SSL_DIR=/etc/etcd/tls" | |||
Environment="ETCD_TRUSTED_CA_FILE=/etc/ssl/certs/etcd-ca.crt" | |||
Environment="ETCD_TRUSTED_CA_FILE=/etc/ssl/certs/etcd-client-ca.crt" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(and the below should be etcd-server.crt
and etcd-server.key
@@ -12,11 +12,11 @@ | |||
Environment="ETCD_LISTEN_CLIENT_URLS=https://0.0.0.0:2379" | |||
Environment="ETCD_LISTEN_PEER_URLS=https://0.0.0.0:2380" | |||
Environment="ETCD_SSL_DIR=/etc/etcd/tls" | |||
Environment="ETCD_TRUSTED_CA_FILE=/etc/ssl/certs/etcd-ca.crt" | |||
Environment="ETCD_TRUSTED_CA_FILE=/etc/ssl/certs/etcd-client-ca.crt" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(and the two lines below)
All fixed |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
awesome, thanks!
coreosbot run e2e |
fix #611