mirror of
https://github.com/hashicorp/vault.git
synced 2026-06-04 06:15:02 -04:00
Add Finalize method to seal.
This commit is contained in:
parent
00327a6027
commit
94d6b3ce94
2 changed files with 10 additions and 0 deletions
|
|
@ -381,6 +381,11 @@ func (c *ServerCommand) Run(args []string) int {
|
|||
listener.Close()
|
||||
}
|
||||
|
||||
err = seal.Finalize()
|
||||
if err != nil {
|
||||
c.Ui.Error(fmt.Sprintf("Error finalizing seals: %v", err))
|
||||
}
|
||||
|
||||
return 0
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -30,6 +30,7 @@ const (
|
|||
type Seal interface {
|
||||
SetCore(*Core)
|
||||
Init() error
|
||||
Finalize() error
|
||||
|
||||
StoredKeysSupported() bool
|
||||
SetStoredKeys([][]byte) error
|
||||
|
|
@ -65,6 +66,10 @@ func (d *DefaultSeal) Init() error {
|
|||
return nil
|
||||
}
|
||||
|
||||
func (d *DefaultSeal) Finalize() error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (d *DefaultSeal) StoredKeysSupported() bool {
|
||||
return false
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue