mirror of
https://github.com/hashicorp/vault.git
synced 2025-09-03 21:11:10 +02:00
Rejig dynamic system view to build without tags
This commit is contained in:
parent
7160809f49
commit
a2c9f18f64
@ -6,6 +6,12 @@ import (
|
|||||||
"github.com/hashicorp/vault/logical"
|
"github.com/hashicorp/vault/logical"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
var (
|
||||||
|
sysViewIsPrimaryFunc = func() bool {
|
||||||
|
return true
|
||||||
|
}
|
||||||
|
)
|
||||||
|
|
||||||
type dynamicSystemView struct {
|
type dynamicSystemView struct {
|
||||||
core *Core
|
core *Core
|
||||||
mountEntry *MountEntry
|
mountEntry *MountEntry
|
||||||
@ -74,3 +80,8 @@ func (d dynamicSystemView) Tainted() bool {
|
|||||||
func (d dynamicSystemView) CachingDisabled() bool {
|
func (d dynamicSystemView) CachingDisabled() bool {
|
||||||
return d.core.cachingDisabled
|
return d.core.cachingDisabled
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Checks if this is a primary Vault instance.
|
||||||
|
func (d dynamicSystemView) IsPrimary() bool {
|
||||||
|
return sysViewIsPrimaryFunc()
|
||||||
|
}
|
||||||
|
@ -1,8 +0,0 @@
|
|||||||
// +build vault,!ent
|
|
||||||
|
|
||||||
package vault
|
|
||||||
|
|
||||||
// IsPrimary checks if this is a primary Vault instance.
|
|
||||||
func (d dynamicSystemView) IsPrimary() bool {
|
|
||||||
return true
|
|
||||||
}
|
|
Loading…
x
Reference in New Issue
Block a user