Documentation
¶
Index ¶
- func CreatePullRequest(scm git.SCMClient, g git.Git, branch, directory string) error
- func GetAvailableUpdates(catalogClient CatalogClient, catalogName, profileName, profileVersion string) ([]profilesv1.ProfileCatalogEntry, error)
- type CatalogClient
- type CatalogManager
- type Clients
- type GitRepoConfig
- type InstallConfig
- type Manager
- func (m *Manager) Install(cfg InstallConfig) error
- func (m *Manager) List(k8sClient runtimeclient.Client, catalogClient CatalogClient, name string) ([]ProfileData, error)
- func (m *Manager) Search(catalogClient CatalogClient, searchName string) ([]profilesv1.ProfileCatalogEntry, error)
- func (m *Manager) Show(catalogClient CatalogClient, catalogName, profileName, profileVersion string) (profilesv1.ProfileCatalogEntry, error)
- type Profile
- type ProfileConfig
- type ProfileData
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CreatePullRequest ¶
CreatePullRequest creates a pull request from the current changes.
func GetAvailableUpdates ¶
func GetAvailableUpdates(catalogClient CatalogClient, catalogName, profileName, profileVersion string) ([]profilesv1.ProfileCatalogEntry, error)
GetAvailableUpdates queries the catalog at catalogURL for profiles which have greater versions than the current given one.
Types ¶
type CatalogClient ¶
type CatalogClient interface {
DoRequest(path string, query map[string]string) ([]byte, int, error)
}
CatalogClient makes requests to the catalog service
type CatalogManager ¶ added in v0.2.0
type CatalogManager interface { Show(CatalogClient, string, string, string) (profilesv1.ProfileCatalogEntry, error) Search(CatalogClient, string) ([]profilesv1.ProfileCatalogEntry, error) Install(InstallConfig) error List(runtimeclient.Client, CatalogClient, string) ([]ProfileData, error) }
CatalogManager inteface for interacting with catalog API
type Clients ¶ added in v0.0.3
type Clients struct { CatalogClient CatalogClient Installer install.ProfileInstaller }
Clients contains a set of clients which are used by install.
type GitRepoConfig ¶ added in v0.2.0
GitConfig contains the configuration of the git repository used to deploy the profile
type InstallConfig ¶
InstallConfig defines parameters for the installation call.
type Manager ¶ added in v0.2.0
type Manager struct{}
Manager is responsible for manager interactions with the catalog API
func (*Manager) Install ¶ added in v0.2.0
func (m *Manager) Install(cfg InstallConfig) error
Install using the catalog at catalogURL and a profile matching the provided profileName generates a profile installation and its artifacts
func (*Manager) List ¶ added in v0.2.0
func (m *Manager) List(k8sClient runtimeclient.Client, catalogClient CatalogClient, name string) ([]ProfileData, error)
List will fetch all installed profiles on the cluster and check if there are updated versions available.
func (*Manager) Search ¶ added in v0.2.0
func (m *Manager) Search(catalogClient CatalogClient, searchName string) ([]profilesv1.ProfileCatalogEntry, error)
Search queries the catalog at catalogURL for profiles matching the provided searchName. If no searchName is provided it returns all profiles
func (*Manager) Show ¶ added in v0.2.0
func (m *Manager) Show(catalogClient CatalogClient, catalogName, profileName, profileVersion string) (profilesv1.ProfileCatalogEntry, error)
Show queries the catalog at catalogURL for a profile matching the provided profileName
type Profile ¶ added in v0.2.0
type Profile struct { GitRepoConfig ProfileConfig }
Profile contains configuration for profiles ie. catalogName, profilesName, etc.
type ProfileConfig ¶ added in v0.0.3
type ProfileData ¶
type ProfileData struct { Profile installation.Summary AvailableVersionUpdates []string }
ProfileData data containing profile and available version update for format printing.