code: func CreateRootCA(rootCN string) (RootCA, error) {
  	// Create a simple CSR for the CA using the default CA validator and policy
  	req := cfcsr.CertificateRequest{
  		CN:         rootCN,
  		KeyRequest: &cfcsr.BasicKeyRequest{A: RootKeyAlgo, S: RootKeySize},
  		CA:         &cfcsr.CAConfig{Expiry: RootCAExpiration},
  	}
  
  	// Generate the CA and get the certificate and private key
  	cert, _, key, err := initca.New(&req)
  	if err != nil {
  		return RootCA{}, err
  	}
  
  	rootCA, err := NewRootCA(cert, cert, key, DefaultNodeCertExpiration, nil)
  	if err != nil {
  		return RootCA{}, err
  	}
  
  	return rootCA, nil
  }
docs: // CreateRootCA creates a Certificate authority for a new Swarm Cluster, potentially
  // overwriting any existing CAs.