Stub updates for Ent (#30890)

This commit is contained in:
Ben Ash 2025-06-06 14:47:39 -04:00 committed by GitHub
parent dad218cba2
commit 9fe8945005
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 24 additions and 1 deletions

3
changelog/30890.txt Normal file
View file

@ -0,0 +1,3 @@
```release-note:change
logical/system: add ent stub for plugin catalog handling
```

View file

@ -203,7 +203,7 @@ func NewSystemBackend(core *Core, logger log.Logger, config *logical.BackendConf
b.Backend.Paths = append(b.Backend.Paths, b.sealPaths()...)
b.Backend.Paths = append(b.Backend.Paths, b.statusPaths()...)
b.Backend.Paths = append(b.Backend.Paths, b.pluginsCatalogListPaths()...)
b.Backend.Paths = append(b.Backend.Paths, b.pluginsCatalogCRUDPath())
b.Backend.Paths = append(b.Backend.Paths, entWrappedPluginsCRUDPath(b)...)
b.Backend.Paths = append(b.Backend.Paths, b.pluginsCatalogPinsListPath())
b.Backend.Paths = append(b.Backend.Paths, b.pluginsCatalogPinsCRUDPath())
b.Backend.Paths = append(b.Backend.Paths, b.pluginsReloadPath())

View file

@ -31,3 +31,7 @@ func (s *SystemBackend) makeSnapshotSource(ctx context.Context, _ *framework.Fie
}
return snapshots.NewManualSnapshotSource(body), nil
}
func entWrappedPluginsCRUDPath(b *SystemBackend) []*framework.Path {
return []*framework.Path{b.pluginsCatalogCRUDPath()}
}

View file

@ -0,0 +1,16 @@
// Copyright (c) HashiCorp, Inc.
// SPDX-License-Identifier: BUSL-1.1
//go:build !enterprise
package plugincatalog
import (
"context"
"github.com/hashicorp/vault/sdk/helper/pluginutil"
)
func (c *PluginCatalog) entPrepareDownloadedPlugin(ctx context.Context, plugin pluginutil.SetPluginInput) (string, string, error) {
return "", "", nil
}