Documentation ¶
Index ¶
- func CreateDefaultDevEnvironment(ns string) *v1.Environment
- func EnsureDevEnvironmentSetup(jxClient versioned.Interface, ns string) (*v1.Environment, error)
- func EnsureDevNamespaceCreatedWithoutEnvironment(kubeClient kubernetes.Interface, ns string) error
- func EnsureEditEnvironmentSetup(kubeClient kubernetes.Interface, jxClient versioned.Interface, ns string, ...) (*v1.Environment, error)
- func EnsureEnvironmentNamespaceSetup(kubeClient kubernetes.Interface, jxClient versioned.Interface, ...) error
- func EnsureNamespaceCreated(kubeClient kubernetes.Interface, name string, labels map[string]string, ...) error
- func GetDevEnvGitOwner(jxClient versioned.Interface) (string, error)
- func GetDevEnvTeamSettings(jxClient versioned.Interface, ns string) (*v1.TeamSettings, error)
- func GetDevEnvironment(jxClient versioned.Interface, ns string) (*v1.Environment, error)
- func GetDevNamespace(kubeClient kubernetes.Interface, ns string) (string, string, error)
- func GetEditEnvironmentNamespace(jxClient versioned.Interface, ns string) (string, error)
- func GetEnrichedDevEnvironment(kubeClient kubernetes.Interface, jxClient versioned.Interface, ns string) (*v1.Environment, error)
- func GetEnvironment(jxClient versioned.Interface, ns string, name string) (*v1.Environment, error)
- func GetEnvironmentNames(jxClient versioned.Interface, ns string) ([]string, error)
- func GetEnvironmentNamespace(jxClient versioned.Interface, ns, environment string) (string, error)
- func GetEnvironments(jxClient versioned.Interface, ns string) (map[string]*v1.Environment, []string, error)
- func GetEnvironmentsByPrURL(jxClient versioned.Interface, ns string, prURL string) (*v1.Environment, error)
- func GetFilteredEnvironmentNames(jxClient versioned.Interface, ns string, ...) ([]string, error)
- func GetOrderedEnvironments(jxClient versioned.Interface, ns string) (map[string]*v1.Environment, []string, error)
- func GetPermanentEnvironments(jxClient versioned.Interface, ns string) ([]*v1.Environment, error)
- func GetPreviewEnvironmentReleaseName(env *v1.Environment) string
- func GetRepositoryGitURL(s *v1.SourceRepository) (string, error)
- func GetTeams(kubeClient kubernetes.Interface) ([]*corev1.Namespace, []string, error)
- func IsIncludedInTheGivenEnvs(environments map[string]*v1.Environment, repository *v1.SourceRepository) bool
- func IsPermanentEnvironment(env *v1.Environment) bool
- func IsPreviewEnvironment(env *v1.Environment) bool
- func ModifyDevEnvironment(kubeClient kubernetes.Interface, jxClient versioned.Interface, ns string, ...) error
- func NewPermanentEnvironment(name string) *v1.Environment
- func NewPermanentEnvironmentWithGit(name string, gitUrl string) *v1.Environment
- func NewPreviewEnvironment(name string) *v1.Environment
- func SortActivities(activities []v1.PipelineActivity)
- func SortEnvironments(environments []v1.Environment)
- type ByOrder
- type ByTimestamp
- type ResolveChartMuseumURLFn
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CreateDefaultDevEnvironment ¶
func CreateDefaultDevEnvironment(ns string) *v1.Environment
CreateDefaultDevEnvironment creates a default development environment
func EnsureDevEnvironmentSetup ¶
EnsureDevEnvironmentSetup ensures that the Environment is created in the given namespace
func EnsureDevNamespaceCreatedWithoutEnvironment ¶
func EnsureDevNamespaceCreatedWithoutEnvironment(kubeClient kubernetes.Interface, ns string) error
EnsureDevNamespaceCreatedWithoutEnvironment ensures that there is a development namespace created
func EnsureEditEnvironmentSetup ¶
func EnsureEditEnvironmentSetup(kubeClient kubernetes.Interface, jxClient versioned.Interface, ns string, username string) (*v1.Environment, error)
EnsureEditEnvironmentSetup ensures that the Environment is created in the given namespace
func EnsureEnvironmentNamespaceSetup ¶
func EnsureEnvironmentNamespaceSetup(kubeClient kubernetes.Interface, jxClient versioned.Interface, env *v1.Environment, ns string) error
func EnsureNamespaceCreated ¶
func EnsureNamespaceCreated(kubeClient kubernetes.Interface, name string, labels map[string]string, annotations map[string]string) error
Ensure that the namespace exists for the given name
func GetDevEnvGitOwner ¶
GetDevEnvGitOwner gets the default GitHub owner/organisation to use for Environment repos. This takes the setting from the 'jx' Dev Env to get the one that was selected at installation time.
func GetDevEnvTeamSettings ¶
GetDevEnvTeamSettings gets the team settings from the specified namespace.
func GetDevEnvironment ¶
GetDevEnvironment returns the current development environment using the jxClient for the given ns. If the Dev Environment cannot be found, returns nil Environment (rather than an error). A non-nil error is only returned if there is an error fetching the Dev Environment.
func GetDevNamespace ¶
GetDevNamespace returns the developer environment namespace which is the namespace that contains the Environments and the developer tools like Jenkins
func GetEditEnvironmentNamespace ¶
GetEditEnvironmentNamespace returns the namespace of the current users edit environment
func GetEnrichedDevEnvironment ¶
func GetEnrichedDevEnvironment(kubeClient kubernetes.Interface, jxClient versioned.Interface, ns string) (*v1.Environment, error)
GetEnrichedDevEnvironment lazily creates the dev namespace if it does not already exist and auto-detects the webhook engine if its not specified
func GetEnvironment ¶
GetEnvironment find an environment by name
func GetEnvironmentNames ¶
GetEnvironmentNames returns the sorted list of environment names
func GetEnvironmentNamespace ¶
GetEnvironments returns the namespace name for a given environment
func GetEnvironments ¶
func GetEnvironments(jxClient versioned.Interface, ns string) (map[string]*v1.Environment, []string, error)
GetEnvironments returns a map of the environments along with a sorted list of names
func GetEnvironmentsByPrURL ¶
func GetEnvironmentsByPrURL(jxClient versioned.Interface, ns string, prURL string) (*v1.Environment, error)
GetEnvironmentsByPrURL find an environment by a pull request URL
func GetFilteredEnvironmentNames ¶
func GetFilteredEnvironmentNames(jxClient versioned.Interface, ns string, fn func(environment *v1.Environment) bool) ([]string, error)
GetFilteredEnvironmentNames returns the sorted list of environment names
func GetOrderedEnvironments ¶
func GetOrderedEnvironments(jxClient versioned.Interface, ns string) (map[string]*v1.Environment, []string, error)
GetOrderedEnvironments returns a map of the environments along with the correctly ordered names
func GetPermanentEnvironments ¶
GetPermanentEnvironments returns a list with the current permanent environments
func GetPreviewEnvironmentReleaseName ¶
func GetPreviewEnvironmentReleaseName(env *v1.Environment) string
GetPreviewEnvironmentReleaseName returns the (helm) release name for the given (preview) environment or the empty string is the environment is not a preview environment, or has no release name associated with it
func GetRepositoryGitURL ¶
func GetRepositoryGitURL(s *v1.SourceRepository) (string, error)
GetRepositoryGitURL returns the git repository clone URL
func IsIncludedInTheGivenEnvs ¶
func IsIncludedInTheGivenEnvs(environments map[string]*v1.Environment, repository *v1.SourceRepository) bool
IsIncludedInTheGivenEnvs returns true if the given repository is an environment repository
func IsPermanentEnvironment ¶
func IsPermanentEnvironment(env *v1.Environment) bool
IsPermanentEnvironment indicates if an environment is permanent
func IsPreviewEnvironment ¶
func IsPreviewEnvironment(env *v1.Environment) bool
func ModifyDevEnvironment ¶
func ModifyDevEnvironment(kubeClient kubernetes.Interface, jxClient versioned.Interface, ns string, callback func(env *v1.Environment) error) error
ModifyDevEnvironment modifies the dev environment
func NewPermanentEnvironment ¶
func NewPermanentEnvironment(name string) *v1.Environment
NewPermanentEnvironment creates a new permanent environment for testing
func NewPermanentEnvironmentWithGit ¶
func NewPermanentEnvironmentWithGit(name string, gitUrl string) *v1.Environment
NewPermanentEnvironment creates a new permanent environment for testing
func NewPreviewEnvironment ¶
func NewPreviewEnvironment(name string) *v1.Environment
NewPreviewEnvironment creates a new preview environment for testing
func SortActivities ¶
func SortActivities(activities []v1.PipelineActivity)
SortActivities sorts a list of PipelineActivities
func SortEnvironments ¶
func SortEnvironments(environments []v1.Environment)
Types ¶
type ByOrder ¶
type ByOrder []v1.Environment
type ByTimestamp ¶
type ByTimestamp []v1.PipelineActivity
ByTimestamp is used to fileter a list of PipelineActivities by their given timestamp
func (ByTimestamp) Len ¶
func (a ByTimestamp) Len() int
func (ByTimestamp) Less ¶
func (a ByTimestamp) Less(i, j int) bool
func (ByTimestamp) Swap ¶
func (a ByTimestamp) Swap(i, j int)
type ResolveChartMuseumURLFn ¶
ResolveChartMuseumURLFn used to resolve the chart repository URL if using remote environments