This commit is contained in:
1 parent
f285b5c904
commit
fcb64a34bd
4 files changed
+31
-5
No files matched your search
@@ -164,12 +164,18 @@ func LoadSecurityContext(ctx *context.Context) {
|
||||
|
||||
func credentialRuntime() *credentials.Service {
|
||||
if service := currentSecurityRuntime().credentials; service != nil {
|
||||
if service.VaultRoot() == "" && config.ROOT_PATH != "" {
|
||||
service.SetVaultRoot(config.ROOT_PATH)
|
||||
}
|
||||
return service
|
||||
}
|
||||
if db.Instance == nil {
|
||||
return nil
|
||||
}
|
||||
service, _ := credentials.NewService(db.Instance)
|
||||
if service != nil && config.ROOT_PATH != "" {
|
||||
service.SetVaultRoot(config.ROOT_PATH)
|
||||
}
|
||||
return service
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user