[peter@minion ~]$ docker swarm join --token SWMTKN-1-3mj5po3c7o04le7quhkdhz6pm9b8ziv3qe0u7hx0hrgxsnaram-0p1f40vtehanu6ugw8ug2wasy 10.0.0.10:2377
Error response from daemon: error while validating Root CA Certificate: x509: certificate has expired or is not yet valid
原理:docker swarm node之間是加密傳輸,docker swarm init時會創建CA證書。這里提示證書過期,可能是主機當前時間不對。
解決:sudo ntpdate time.nist.gov 同步一下時間