Skip to content

Commit b082c05

Browse files
committed
Specify default Vault backend node
Without passing `-node`, Vault will panic: ``` panic: runtime error: index out of range goroutine 1 [running]: panic(0xb9ece0, 0xc820010040) /usr/local/go/src/runtime/panic.go:464 +0x3e6 github.com/kelseyhightower/confd/backends.New(0x0, 0x0, 0x0, 0x0, 0x7fff1a2aee58, 0x5, 0x0, 0x0, 0x0, 0x0, ...) /Users/kelseyhightower/go/src/github.com/kelseyhightower/confd/backends/client.go:61 +0xbdf main.main() /Users/kelseyhightower/go/src/github.com/kelseyhightower/confd/confd.go:27 +0x1f4 ```
1 parent b34d223 commit b082c05

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

config.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -178,6 +178,8 @@ func initConfig() error {
178178
}
179179
case "redis":
180180
config.BackendNodes = []string{"127.0.0.1:6379"}
181+
case "vault":
182+
config.BackendNodes = []string{"http://127.0.0.1:8200"}
181183
case "zookeeper":
182184
config.BackendNodes = []string{"127.0.0.1:2181"}
183185
}

0 commit comments

Comments
 (0)