This package provides utility for using etcd.
Programs using this package can implement following common specifications.
The etcd parameters can be embedded in YAML or JSON file.
endpoints:
- http://10.1.2.3:2379
- http://10.11.12.13:2379
prefix: "/key-prefix/"
timeout: "2s"
# user/pass authentication
username: "etcd-user-name"
password: "etcd-password"
# etcd server certificates' CA
tls-ca-file: "/etc/ssl/my-ca.crt"
# etcd client certificate authentication
tls-cert-file: "/path/to/my-user.crt"
tls-key-file: "/path/to/my-user.key"
# certificats may be embedded
tls-ca: |
-----BEGIN CERTIFICATE-----
MIICAzCCAWwCCQCgYvbe6d0oLzANBgkqhkiG9w0BAQUFADBGMQswCQYDVQQGEwJK
....
-----END CERTIFICATE-----
tls-cert: |
-----BEGIN CERTIFICATE-----
MIICAzCCAWwCCQCgYvbe6d0oLzANBgkqhkiG9w0BAQUFADBGMQswCQYDVQQGEwJK
....
-----END CERTIFICATE-----
tls-key: |
-----BEGIN PRIVATE KEY-----
MIICAzCCAWwCCQCgYvbe6d0oLzANBgkqhkiG9w0BAQUFADBGMQswCQYDVQQGEwJK
....
-----END PRIVATE KEY-----
Name | Default | Description |
---|---|---|
etcd-endpoints |
http://127.0.0.1:2379 |
comma-separated URLs of the backend etcd |
etcd-password |
password for etcd authentication | |
etcd-prefix |
prefix for etcd keys | |
etcd-timeout |
2s |
dial timeout duration to etcd |
etcd-tls-ca |
Path to CA bundle used to verify etcd server certificates. | |
etcd-tls-cert |
Path to client certificate file of an etcd user. | |
etcd-tls-key |
Path to private key file of an etcd user. | |
etcd-username |
username for etcd authentication |
Read the documentation.
etcdutil is licensed under the Apache License, Version 2.0.