traefik/docs/configuration/backends/etcd.md

76 lines
1.4 KiB
Markdown
Raw Normal View History

# Etcd Backend
2017-08-25 19:32:33 +00:00
2017-09-11 17:10:04 +00:00
Træfik can be configured to use Etcd as a backend configuration.
2017-08-25 19:32:33 +00:00
```toml
################################################################
# Etcd configuration backend
################################################################
2017-09-11 17:10:04 +00:00
# Enable Etcd configuration backend.
2017-08-25 19:32:33 +00:00
[etcd]
2017-09-11 17:10:04 +00:00
# Etcd server endpoint.
2017-08-25 19:32:33 +00:00
#
# Required
2017-09-11 17:10:04 +00:00
# Default: "127.0.0.1:2379"
2017-08-25 19:32:33 +00:00
#
endpoint = "127.0.0.1:2379"
2017-09-11 17:10:04 +00:00
# Enable watch Etcd changes.
2017-08-25 19:32:33 +00:00
#
# Optional
2017-09-11 17:10:04 +00:00
# Default: true
2017-08-25 19:32:33 +00:00
#
watch = true
# Prefix used for KV store.
#
# Optional
2017-09-11 17:10:04 +00:00
# Default: "/traefik"
2017-08-25 19:32:33 +00:00
#
prefix = "/traefik"
2017-11-17 16:22:03 +00:00
# Force to use API V3 (otherwise still use API V2)
#
# Deprecated
#
# Optional
# Default: false
#
useAPIV3 = true
2017-09-11 17:10:04 +00:00
# Override default configuration template.
# For advanced users :)
2017-08-25 19:32:33 +00:00
#
# Optional
#
# filename = "etcd.tmpl"
2017-09-11 17:10:04 +00:00
# Use etcd user/pass authentication.
2017-08-25 19:32:33 +00:00
#
# Optional
#
# username = foo
# password = bar
2017-09-11 17:10:04 +00:00
# Enable etcd TLS connection.
2017-08-25 19:32:33 +00:00
#
# Optional
#
2017-09-11 17:10:04 +00:00
# [etcd.tls]
# ca = "/etc/ssl/ca.crt"
# cert = "/etc/ssl/etcd.crt"
# key = "/etc/ssl/etcd.key"
# insecureskipverify = true
2017-08-25 19:32:33 +00:00
```
2017-09-11 17:10:04 +00:00
To enable constraints see [backend-specific constraints section](/configuration/commons/#backend-specific).
Please refer to the [Key Value storage structure](/user-guide/kv-config/#key-value-storage-structure) section to get documentation on Traefik KV structure.
2017-11-17 16:22:03 +00:00
!!! note
The option `useAPIV3` allows using Etcd API V3 only if it's set to true.
This option is **deprecated** and API V2 won't be supported in the future.