Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Backend ¶
type Backend interface { // WorkspaceStorage returns the workspace storage and init default workspace. WorkspaceStorage() (workspace.Storage, error) // ReleaseStorage returns the release storage. ReleaseStorage(project, workspace string) (release.Storage, error) // StateStorageWithPath returns the state storage with the specified path. StateStorageWithPath(path string) (release.Storage, error) // GraphStorage returns the graph storage. GraphStorage(project, workspace string) (graph.Storage, error) // ProjectStorage returns the project directory under release folder. ProjectStorage() (map[string][]string, error) }
Backend is used to provide the storage service for Workspace, Spec and State.
func NewBackend ¶
NewBackend creates the Backend with the configuration set in the Kusion configuration file, where the input is the configured backend name. If the backend configuration is invalid, NewBackend will get failed. If the input name is empty, use the current backend. If no current backend is specified or backends config is empty, and the input name is empty, use the default local storage.
Click to show internal directories.
Click to hide internal directories.