2021-10-31 09:05:38 +08:00
|
|
|
package discov
|
|
|
|
|
2022-01-04 15:51:32 +08:00
|
|
|
import "github.com/zeromicro/go-zero/core/discov/internal"
|
2021-10-31 09:05:38 +08:00
|
|
|
|
2021-12-30 17:44:15 +08:00
|
|
|
// RegisterAccount registers the username/password to the given etcd cluster.
|
2021-10-31 09:05:38 +08:00
|
|
|
func RegisterAccount(endpoints []string, user, pass string) {
|
|
|
|
internal.AddAccount(endpoints, user, pass)
|
|
|
|
}
|
2022-01-02 20:23:50 +08:00
|
|
|
|
|
|
|
// RegisterTLS registers the CertFile/CertKeyFile/CACertFile to the given etcd.
|
|
|
|
func RegisterTLS(endpoints []string, certFile, certKeyFile, caFile string,
|
|
|
|
insecureSkipVerify bool) error {
|
|
|
|
return internal.AddTLS(endpoints, certFile, certKeyFile, caFile, insecureSkipVerify)
|
|
|
|
}
|