mirror of
https://github.com/optim-enterprises-bv/vault.git
synced 2025-10-30 18:17:55 +00:00
http: prefix with v1
This commit is contained in:
@@ -11,9 +11,9 @@ import (
|
|||||||
// its own to mount the Vault API within another web server.
|
// its own to mount the Vault API within another web server.
|
||||||
func Handler(core *vault.Core) http.Handler {
|
func Handler(core *vault.Core) http.Handler {
|
||||||
mux := http.NewServeMux()
|
mux := http.NewServeMux()
|
||||||
mux.Handle("/sys/seal-status", handleSysSealStatus(core))
|
mux.Handle("/v1/sys/seal-status", handleSysSealStatus(core))
|
||||||
mux.Handle("/sys/seal", handleSysSeal(core))
|
mux.Handle("/v1/sys/seal", handleSysSeal(core))
|
||||||
mux.Handle("/sys/unseal", handleSysUnseal(core))
|
mux.Handle("/v1/sys/unseal", handleSysUnseal(core))
|
||||||
return mux
|
return mux
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -12,7 +12,7 @@ func TestSysSealStatus(t *testing.T) {
|
|||||||
ln, addr := testServer(t, core)
|
ln, addr := testServer(t, core)
|
||||||
defer ln.Close()
|
defer ln.Close()
|
||||||
|
|
||||||
resp, err := http.Get(addr + "/sys/seal-status")
|
resp, err := http.Get(addr + "/v1/sys/seal-status")
|
||||||
if err != nil {
|
if err != nil {
|
||||||
t.Fatalf("err: %s", err)
|
t.Fatalf("err: %s", err)
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user