Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DeploymentBuilder ¶
type DeploymentBuilder func(repos.TrackedRepository) (*appsv1.Deployment, error)
DeploymentBuilder builds a Deployment based on the given TrackedRepository
type DeploymentCheck ¶
type DeploymentCheck func(repos.TrackedRepository) bool
DeploymentCheck is called to decide whether a deployment should be created for a given TrackedRepository.
type DeploymentNamer ¶
type DeploymentNamer func(repos.TrackedRepository) (string, error)
DeploymentNamer is called to determine what to name a Deployment Given a TrackedRepository
type DeploymentPrep ¶
type DeploymentPrep func(repos.TrackedRepository) error
DeploymentPrep is called before building a deployment. This can be used to provision additional resources before the Deployment is applied
type K8sConfiguration ¶
type K8sConfiguration struct { ServiceNamer ServiceNamer DeploymentNamer DeploymentNamer ServiceBuilder ServiceBuilder DeploymentBuilder DeploymentBuilder PreDeploy DeploymentPrep ShouldDeploy DeploymentCheck }
K8sConfiguration is a struct to describe the set of operations a K8SSupervisor needs to manage a cluster
type ServiceBuilder ¶
type ServiceBuilder func(repos.TrackedRepository) (*apiv1.Service, error)
ServiceBuilder buidls a Service based on the given TrackedRepository
type ServiceNamer ¶
type ServiceNamer func(repos.TrackedRepository) (string, error)
ServiceNamer is called to determine what to name a Service Given a TrackedRepository
type Supervisor ¶
Supervisor exists to supervise a set of deployments
func NewK8sSupervisor ¶
func NewK8sSupervisor(log *logrus.Logger, clientset kubernetes.Interface, kconfig K8sConfiguration, rl repos.RepoList, appid string) (Supervisor, error)
NewK8sSupervisor creates a new supervisor backed by Kubernetes