Documentation ¶
Index ¶
- Constants
- Variables
- func GenerateProcessGUID() string
- type AddDestinationsToRouteMessage
- type AppEnvVarsRecord
- type AppRecord
- type AppRepo
- func (f *AppRepo) CreateApp(ctx context.Context, authInfo authorization.Info, ...) (AppRecord, error)
- func (f *AppRepo) CreateOrPatchAppEnvVars(ctx context.Context, authInfo authorization.Info, ...) (AppEnvVarsRecord, error)
- func (f *AppRepo) DeleteApp(ctx context.Context, authInfo authorization.Info, message DeleteAppMessage) error
- func (f *AppRepo) GetApp(ctx context.Context, authInfo authorization.Info, appGUID string) (AppRecord, error)
- func (f *AppRepo) GetAppByNameAndSpace(ctx context.Context, authInfo authorization.Info, appName string, ...) (AppRecord, error)
- func (f *AppRepo) GetAppEnv(ctx context.Context, authInfo authorization.Info, appGUID string) (map[string]string, error)
- func (f *AppRepo) ListApps(ctx context.Context, authInfo authorization.Info, message ListAppsMessage) ([]AppRecord, error)
- func (f *AppRepo) PatchAppEnvVars(ctx context.Context, authInfo authorization.Info, ...) (AppEnvVarsRecord, error)
- func (f *AppRepo) SetAppDesiredState(ctx context.Context, authInfo authorization.Info, ...) (AppRecord, error)
- func (f *AppRepo) SetCurrentDroplet(ctx context.Context, authInfo authorization.Info, ...) (CurrentDropletRecord, error)
- type AuthorizedInChecker
- type BuildRecord
- type BuildRepo
- type BuildpackRecord
- type BuildpackRepository
- type CFSpaceRepository
- type CreateAppMessage
- type CreateBuildMessage
- type CreateOrPatchAppEnvVarsMessage
- type CreateOrgMessage
- type CreatePackageMessage
- type CreateProcessMessage
- type CreateRoleMessage
- type CreateRouteMessage
- type CreateServiceBindingMessage
- type CreateServiceInstanceMessage
- type CreateSpaceMessage
- type CurrentDropletRecord
- type DeleteAppMessage
- type DeleteOrgMessage
- type DeleteRouteMessage
- type DeleteServiceBindingMessage
- type DeleteServiceInstanceMessage
- type DeleteSpaceMessage
- type DesiredState
- type DestinationMessage
- type DestinationRecord
- type DomainRecord
- type DomainRepo
- func (r *DomainRepo) GetDomain(ctx context.Context, authInfo authorization.Info, domainGUID string) (DomainRecord, error)
- func (r *DomainRepo) GetDomainByName(ctx context.Context, authInfo authorization.Info, domainName string) (DomainRecord, error)
- func (r *DomainRepo) ListDomains(ctx context.Context, authInfo authorization.Info, message ListDomainsMessage) ([]DomainRecord, error)
- type DropletRecord
- type DropletRepo
- type HealthCheck
- type HealthCheckData
- type ImageBuilder
- type ImagePusher
- type ImageRepository
- type Lifecycle
- type LifecycleData
- type ListAppsMessage
- type ListBuildpacksMessage
- type ListDomainsMessage
- type ListDropletsMessage
- type ListOrgsMessage
- type ListPackagesMessage
- type ListPodStatsMessage
- type ListProcessesMessage
- type ListRoutesMessage
- type ListServiceBindingsMessage
- type ListServiceInstanceMessage
- type ListSpacesMessage
- type MetricsFetcherFn
- type NamespaceGetter
- type NamespaceRetriever
- type OrgRecord
- type OrgRepo
- func (r *OrgRepo) CreateOrg(ctx context.Context, info authorization.Info, org CreateOrgMessage) (OrgRecord, error)
- func (r *OrgRepo) CreateSpace(ctx context.Context, info authorization.Info, message CreateSpaceMessage) (SpaceRecord, error)
- func (r *OrgRepo) DeleteOrg(ctx context.Context, info authorization.Info, message DeleteOrgMessage) error
- func (r *OrgRepo) DeleteSpace(ctx context.Context, info authorization.Info, message DeleteSpaceMessage) error
- func (r *OrgRepo) GetOrg(ctx context.Context, info authorization.Info, orgGUID string) (OrgRecord, error)
- func (r *OrgRepo) GetSpace(ctx context.Context, info authorization.Info, spaceGUID string) (SpaceRecord, error)
- func (r *OrgRepo) ListOrgs(ctx context.Context, info authorization.Info, filter ListOrgsMessage) ([]OrgRecord, error)
- func (r *OrgRepo) ListSpaces(ctx context.Context, info authorization.Info, message ListSpacesMessage) ([]SpaceRecord, error)
- type PackageRecord
- type PackageRepo
- func (r *PackageRepo) CreatePackage(ctx context.Context, authInfo authorization.Info, message CreatePackageMessage) (PackageRecord, error)
- func (r *PackageRepo) GetPackage(ctx context.Context, authInfo authorization.Info, guid string) (PackageRecord, error)
- func (r *PackageRepo) ListPackages(ctx context.Context, authInfo authorization.Info, message ListPackagesMessage) ([]PackageRecord, error)
- func (r *PackageRepo) UpdatePackageSource(ctx context.Context, authInfo authorization.Info, ...) (PackageRecord, error)
- type PatchAppEnvVarsMessage
- type PatchProcessMessage
- type PodRepo
- type PodStatsRecord
- type PrivilegedClientFactory
- type ProcessRecord
- type ProcessRepo
- func (r *ProcessRepo) CreateProcess(ctx context.Context, authInfo authorization.Info, message CreateProcessMessage) error
- func (r *ProcessRepo) GetProcess(ctx context.Context, authInfo authorization.Info, processGUID string) (ProcessRecord, error)
- func (r *ProcessRepo) GetProcessByAppTypeAndSpace(ctx context.Context, authInfo authorization.Info, ...) (ProcessRecord, error)
- func (r *ProcessRepo) ListProcesses(ctx context.Context, authInfo authorization.Info, message ListProcessesMessage) ([]ProcessRecord, error)
- func (r *ProcessRepo) PatchProcess(ctx context.Context, authInfo authorization.Info, message PatchProcessMessage) (ProcessRecord, error)
- func (r *ProcessRepo) ScaleProcess(ctx context.Context, authInfo authorization.Info, ...) (ProcessRecord, error)
- type ProcessScaleValues
- type RoleRecord
- type RoleRepo
- type RouteRecord
- type RouteRepo
- func (f *RouteRepo) AddDestinationsToRoute(ctx context.Context, authInfo authorization.Info, ...) (RouteRecord, error)
- func (f *RouteRepo) CreateRoute(ctx context.Context, authInfo authorization.Info, message CreateRouteMessage) (RouteRecord, error)
- func (f *RouteRepo) DeleteRoute(ctx context.Context, authInfo authorization.Info, message DeleteRouteMessage) error
- func (f *RouteRepo) GetOrCreateRoute(ctx context.Context, authInfo authorization.Info, message CreateRouteMessage) (RouteRecord, error)
- func (f *RouteRepo) GetRoute(ctx context.Context, authInfo authorization.Info, routeGUID string) (RouteRecord, error)
- func (f *RouteRepo) ListRoutes(ctx context.Context, authInfo authorization.Info, message ListRoutesMessage) ([]RouteRecord, error)
- func (f *RouteRepo) ListRoutesForApp(ctx context.Context, authInfo authorization.Info, appGUID string, ...) ([]RouteRecord, error)
- type ScaleProcessMessage
- type ServiceBindingLastOperation
- type ServiceBindingRecord
- type ServiceBindingRepo
- func (r *ServiceBindingRepo) CreateServiceBinding(ctx context.Context, authInfo authorization.Info, ...) (ServiceBindingRecord, error)
- func (r *ServiceBindingRepo) DeleteServiceBinding(ctx context.Context, authInfo authorization.Info, guid string) error
- func (r *ServiceBindingRepo) ListServiceBindings(ctx context.Context, authInfo authorization.Info, ...) ([]ServiceBindingRecord, error)
- func (r *ServiceBindingRepo) ServiceBindingExists(ctx context.Context, authInfo authorization.Info, ...) (bool, error)
- type ServiceInstanceRecord
- type ServiceInstanceRepo
- func (r *ServiceInstanceRepo) CreateServiceInstance(ctx context.Context, authInfo authorization.Info, ...) (ServiceInstanceRecord, error)
- func (r *ServiceInstanceRepo) DeleteServiceInstance(ctx context.Context, authInfo authorization.Info, ...) error
- func (r *ServiceInstanceRepo) GetServiceInstance(ctx context.Context, authInfo authorization.Info, guid string) (ServiceInstanceRecord, error)
- func (r *ServiceInstanceRepo) ListServiceInstances(ctx context.Context, authInfo authorization.Info, ...) ([]ServiceInstanceRecord, error)
- type SetAppDesiredStateMessage
- type SetCurrentDropletMessage
- type SpaceRecord
- type UnprivilegedClientFactory
- type UpdatePackageSourceMessage
- type Usage
- type UserK8sClientFactory
Constants ¶
View Source
const ( StartedState DesiredState = "STARTED" StoppedState DesiredState = "STOPPED" Kind string = "CFApp" APIVersion string = "workloads.cloudfoundry.org/v1alpha1" TimestampFormat string = time.RFC3339 CFAppGUIDLabel string = "workloads.cloudfoundry.org/app-guid" AppResourceType string = "App" AppEnvResourceType string = "App Env" )
View Source
const ( BuildStateStaging = "STAGING" BuildStateStaged = "STAGED" BuildStateFailed = "FAILED" StagingConditionType = "Staging" SucceededConditionType = "Succeeded" BuildResourceType = "Build" )
View Source
const ( OrgNameLabel = "cloudfoundry.org/org-name" SpaceNameLabel = "cloudfoundry.org/space-name" OrgResourceType = "Org" SpaceResourceType = "Space" OrgPrefix = "cf-org-" SpacePrefix = "cf-space-" )
View Source
const ( PackageStateAwaitingUpload = "AWAITING_UPLOAD" PackageStateReady = "READY" PackageResourceType = "Package" )
View Source
const ( RunningState = "RUNNING" ProcessStatsResourceType = "Process Stats" PodMetricsResourceType = "Pod Metrics" )
View Source
const ( RoleGuidLabel = "cloudfoundry.org/role-guid" RoleResourceType = "Role" )
View Source
const ( RouteResourceType = "Route" RoutePrefix = "cf-route-" )
View Source
const ( LabelServiceBindingProvisionedService = "servicebinding.io/provisioned-service" ServiceBindingResourceType = "Service Binding" ServiceBindingTypeApp = "app" )
View Source
const ( CFServiceInstanceGUIDLabel = "services.cloudfoundry.org/service-instance-guid" ServiceInstanceResourceType = "Service Instance" )
View Source
const (
DomainResourceType = "Domain"
)
View Source
const (
DropletResourceType = "Droplet"
)
View Source
const (
ProcessResourceType = "Process"
)
View Source
const SourceImageResourceType = "SourceImage"
Variables ¶
View Source
var ( CFAppsGVR = schema.GroupVersionResource{ Group: "workloads.cloudfoundry.org", Version: "v1alpha1", Resource: "cfapps", } CFBuildsGVR = schema.GroupVersionResource{ Group: "workloads.cloudfoundry.org", Version: "v1alpha1", Resource: "cfbuilds", } CFDomainsGVR = schema.GroupVersionResource{ Group: "networking.cloudfoundry.org", Version: "v1alpha1", Resource: "cfdomains", } CFDropletsGVR = schema.GroupVersionResource{ Group: "workloads.cloudfoundry.org", Version: "v1alpha1", Resource: "cfbuilds", } CFPackagesGVR = schema.GroupVersionResource{ Group: "workloads.cloudfoundry.org", Version: "v1alpha1", Resource: "cfpackages", } CFProcessesGVR = schema.GroupVersionResource{ Group: "workloads.cloudfoundry.org", Version: "v1alpha1", Resource: "cfprocesses", } CFRoutesGVR = schema.GroupVersionResource{ Group: "networking.cloudfoundry.org", Version: "v1alpha1", Resource: "cfroutes", } CFServiceBindingsGVR = schema.GroupVersionResource{ Group: "services.cloudfoundry.org", Version: "v1alpha1", Resource: "cfservicebindings", } CFServiceInstancesGVR = schema.GroupVersionResource{ Group: "services.cloudfoundry.org", Version: "v1alpha1", Resource: "cfserviceinstances", } ResourceMap = map[string]schema.GroupVersionResource{ AppResourceType: CFAppsGVR, BuildResourceType: CFBuildsGVR, DropletResourceType: CFDropletsGVR, DomainResourceType: CFDomainsGVR, PackageResourceType: CFPackagesGVR, ProcessResourceType: CFProcessesGVR, RouteResourceType: CFRoutesGVR, ServiceBindingResourceType: CFServiceBindingsGVR, ServiceInstanceResourceType: CFServiceInstancesGVR, } )
Functions ¶
func GenerateProcessGUID ¶
func GenerateProcessGUID() string
Types ¶
type AddDestinationsToRouteMessage ¶
type AddDestinationsToRouteMessage struct { RouteGUID string SpaceGUID string ExistingDestinations []DestinationRecord NewDestinations []DestinationMessage }
type AppEnvVarsRecord ¶
type AppRepo ¶
type AppRepo struct {
// contains filtered or unexported fields
}
func NewAppRepo ¶
func NewAppRepo( privilegedClient client.Client, namespaceRetriever NamespaceRetriever, userClientFactory UserK8sClientFactory, authPerms *authorization.NamespacePermissions, ) *AppRepo
func (*AppRepo) CreateApp ¶
func (f *AppRepo) CreateApp(ctx context.Context, authInfo authorization.Info, appCreateMessage CreateAppMessage) (AppRecord, error)
func (*AppRepo) CreateOrPatchAppEnvVars ¶
func (f *AppRepo) CreateOrPatchAppEnvVars(ctx context.Context, authInfo authorization.Info, envVariables CreateOrPatchAppEnvVarsMessage) (AppEnvVarsRecord, error)
func (*AppRepo) DeleteApp ¶
func (f *AppRepo) DeleteApp(ctx context.Context, authInfo authorization.Info, message DeleteAppMessage) error
func (*AppRepo) GetAppByNameAndSpace ¶
func (*AppRepo) ListApps ¶
func (f *AppRepo) ListApps(ctx context.Context, authInfo authorization.Info, message ListAppsMessage) ([]AppRecord, error)
func (*AppRepo) PatchAppEnvVars ¶
func (f *AppRepo) PatchAppEnvVars(ctx context.Context, authInfo authorization.Info, message PatchAppEnvVarsMessage) (AppEnvVarsRecord, error)
func (*AppRepo) SetAppDesiredState ¶
func (f *AppRepo) SetAppDesiredState(ctx context.Context, authInfo authorization.Info, message SetAppDesiredStateMessage) (AppRecord, error)
func (*AppRepo) SetCurrentDroplet ¶
func (f *AppRepo) SetCurrentDroplet(ctx context.Context, authInfo authorization.Info, message SetCurrentDropletMessage) (CurrentDropletRecord, error)
type AuthorizedInChecker ¶
type BuildRecord ¶
type BuildRepo ¶
type BuildRepo struct {
// contains filtered or unexported fields
}
func NewBuildRepo ¶
func NewBuildRepo(namespaceRetriever NamespaceRetriever, userClientFactory UserK8sClientFactory) *BuildRepo
func (*BuildRepo) CreateBuild ¶
func (b *BuildRepo) CreateBuild(ctx context.Context, authInfo authorization.Info, message CreateBuildMessage) (BuildRecord, error)
func (*BuildRepo) GetBuild ¶
func (b *BuildRepo) GetBuild(ctx context.Context, authInfo authorization.Info, buildGUID string) (BuildRecord, error)
type BuildpackRecord ¶
type BuildpackRepository ¶
type BuildpackRepository struct {
// contains filtered or unexported fields
}
func NewBuildpackRepository ¶
func NewBuildpackRepository( userClientFactory UserK8sClientFactory, ) *BuildpackRepository
func (*BuildpackRepository) GetBuildpacksForBuilder ¶
func (r *BuildpackRepository) GetBuildpacksForBuilder(ctx context.Context, authInfo authorization.Info, builderName string) ([]BuildpackRecord, error)
type CFSpaceRepository ¶
type CFSpaceRepository interface { CreateSpace(context.Context, authorization.Info, CreateSpaceMessage) (SpaceRecord, error) ListSpaces(context.Context, authorization.Info, ListSpacesMessage) ([]SpaceRecord, error) GetSpace(context.Context, authorization.Info, string) (SpaceRecord, error) DeleteSpace(context.Context, authorization.Info, DeleteSpaceMessage) error }
type CreateAppMessage ¶
type CreateBuildMessage ¶
type CreateOrgMessage ¶
type CreatePackageMessage ¶
type CreatePackageMessage struct { Type string AppGUID string SpaceGUID string OwnerRef metav1.OwnerReference }
type CreateProcessMessage ¶
type CreateRoleMessage ¶
type CreateRouteMessage ¶
type CreateSpaceMessage ¶
type CurrentDropletRecord ¶
type DeleteAppMessage ¶
type DeleteOrgMessage ¶
type DeleteOrgMessage struct {
GUID string
}
type DeleteRouteMessage ¶
type DeleteServiceBindingMessage ¶
type DeleteServiceBindingMessage struct {
GUID string
}
type DeleteSpaceMessage ¶
type DesiredState ¶
type DesiredState string
type DestinationMessage ¶
type DestinationRecord ¶
type DomainRecord ¶
type DomainRepo ¶
type DomainRepo struct {
// contains filtered or unexported fields
}
func NewDomainRepo ¶
func NewDomainRepo( userClientFactory UserK8sClientFactory, namespaceRetriever NamespaceRetriever, rootNamespace string, ) *DomainRepo
func (*DomainRepo) GetDomain ¶
func (r *DomainRepo) GetDomain(ctx context.Context, authInfo authorization.Info, domainGUID string) (DomainRecord, error)
func (*DomainRepo) GetDomainByName ¶
func (r *DomainRepo) GetDomainByName(ctx context.Context, authInfo authorization.Info, domainName string) (DomainRecord, error)
func (*DomainRepo) ListDomains ¶
func (r *DomainRepo) ListDomains(ctx context.Context, authInfo authorization.Info, message ListDomainsMessage) ([]DomainRecord, error)
type DropletRecord ¶
type DropletRepo ¶
type DropletRepo struct {
// contains filtered or unexported fields
}
func NewDropletRepo ¶
func NewDropletRepo( userClientFactory UserK8sClientFactory, namespaceRetriever NamespaceRetriever, namespacePermissions *authorization.NamespacePermissions, ) *DropletRepo
func (*DropletRepo) GetDroplet ¶
func (r *DropletRepo) GetDroplet(ctx context.Context, authInfo authorization.Info, dropletGUID string) (DropletRecord, error)
func (*DropletRepo) ListDroplets ¶
func (r *DropletRepo) ListDroplets(ctx context.Context, authInfo authorization.Info, message ListDropletsMessage) ([]DropletRecord, error)
type HealthCheck ¶
type HealthCheck struct { Type string Data HealthCheckData }
type HealthCheckData ¶
type ImageBuilder ¶
type ImagePusher ¶
type ImageRepository ¶
type ImageRepository struct {
// contains filtered or unexported fields
}
func NewImageRepository ¶
func NewImageRepository( privilegedK8sClient k8sclient.Interface, userClientFactory UserK8sClientFactory, rootNamespace, registrySecretName string, builder ImageBuilder, pusher ImagePusher, ) *ImageRepository
func (*ImageRepository) UploadSourceImage ¶
type Lifecycle ¶
type Lifecycle struct { Type string Data LifecycleData }
type LifecycleData ¶
type ListAppsMessage ¶
type ListBuildpacksMessage ¶
type ListBuildpacksMessage struct {
OrderBy []string
}
type ListDomainsMessage ¶
type ListDomainsMessage struct {
Names []string
}
type ListDropletsMessage ¶
type ListDropletsMessage struct {
PackageGUIDs []string
}
type ListOrgsMessage ¶
type ListPackagesMessage ¶
type ListPodStatsMessage ¶
type ListProcessesMessage ¶
type ListRoutesMessage ¶
type ListSpacesMessage ¶
type MetricsFetcherFn ¶
type MetricsFetcherFn func(ctx context.Context, namespace, name string) (*metricsv1beta1.PodMetrics, error)
func CreateMetricsFetcher ¶
func CreateMetricsFetcher(k8sClientConfig *rest.Config) (MetricsFetcherFn, error)
type NamespaceGetter ¶
type NamespaceRetriever ¶
type NamespaceRetriever struct {
// contains filtered or unexported fields
}
func NewNamespaceRetriver ¶
func NewNamespaceRetriver(client dynamic.Interface) NamespaceRetriever
func (NamespaceRetriever) NamespaceFor ¶
type OrgRepo ¶
type OrgRepo struct {
// contains filtered or unexported fields
}
func NewOrgRepo ¶
func NewOrgRepo( rootNamespace string, privilegedClient client.WithWatch, userClientFactory UserK8sClientFactory, nsPerms *authorization.NamespacePermissions, timeout time.Duration, authEnabled bool, ) *OrgRepo
func (*OrgRepo) CreateOrg ¶
func (r *OrgRepo) CreateOrg(ctx context.Context, info authorization.Info, org CreateOrgMessage) (OrgRecord, error)
func (*OrgRepo) CreateSpace ¶
func (r *OrgRepo) CreateSpace(ctx context.Context, info authorization.Info, message CreateSpaceMessage) (SpaceRecord, error)
func (*OrgRepo) DeleteOrg ¶
func (r *OrgRepo) DeleteOrg(ctx context.Context, info authorization.Info, message DeleteOrgMessage) error
func (*OrgRepo) DeleteSpace ¶
func (r *OrgRepo) DeleteSpace(ctx context.Context, info authorization.Info, message DeleteSpaceMessage) error
func (*OrgRepo) GetSpace ¶
func (r *OrgRepo) GetSpace(ctx context.Context, info authorization.Info, spaceGUID string) (SpaceRecord, error)
func (*OrgRepo) ListOrgs ¶
func (r *OrgRepo) ListOrgs(ctx context.Context, info authorization.Info, filter ListOrgsMessage) ([]OrgRecord, error)
func (*OrgRepo) ListSpaces ¶
func (r *OrgRepo) ListSpaces(ctx context.Context, info authorization.Info, message ListSpacesMessage) ([]SpaceRecord, error)
type PackageRecord ¶
type PackageRepo ¶
type PackageRepo struct {
// contains filtered or unexported fields
}
func NewPackageRepo ¶
func NewPackageRepo( userClientFactory UserK8sClientFactory, namespaceRetriever NamespaceRetriever, authPerms *authorization.NamespacePermissions, ) *PackageRepo
func (*PackageRepo) CreatePackage ¶
func (r *PackageRepo) CreatePackage(ctx context.Context, authInfo authorization.Info, message CreatePackageMessage) (PackageRecord, error)
func (*PackageRepo) GetPackage ¶
func (r *PackageRepo) GetPackage(ctx context.Context, authInfo authorization.Info, guid string) (PackageRecord, error)
func (*PackageRepo) ListPackages ¶
func (r *PackageRepo) ListPackages(ctx context.Context, authInfo authorization.Info, message ListPackagesMessage) ([]PackageRecord, error)
func (*PackageRepo) UpdatePackageSource ¶
func (r *PackageRepo) UpdatePackageSource(ctx context.Context, authInfo authorization.Info, message UpdatePackageSourceMessage) (PackageRecord, error)
type PatchAppEnvVarsMessage ¶
type PatchProcessMessage ¶
type PodRepo ¶
type PodRepo struct {
// contains filtered or unexported fields
}
func NewPodRepo ¶
func NewPodRepo( userClientFactory UserK8sClientFactory, metricsFetcher MetricsFetcherFn, ) *PodRepo
func (*PodRepo) ListPodStats ¶
func (r *PodRepo) ListPodStats(ctx context.Context, authInfo authorization.Info, message ListPodStatsMessage) ([]PodStatsRecord, error)
type PodStatsRecord ¶
type PrivilegedClientFactory ¶
type PrivilegedClientFactory struct {
// contains filtered or unexported fields
}
func NewPrivilegedClientFactory ¶
func NewPrivilegedClientFactory(config *rest.Config, mapper meta.RESTMapper) PrivilegedClientFactory
func (PrivilegedClientFactory) BuildClient ¶
func (f PrivilegedClientFactory) BuildClient(_ authorization.Info) (client.WithWatch, error)
type ProcessRecord ¶
type ProcessRepo ¶
type ProcessRepo struct {
// contains filtered or unexported fields
}
func NewProcessRepo ¶
func NewProcessRepo(privilegedClient client.Client, namespaceRetriever NamespaceRetriever, userClientFactory UserK8sClientFactory, namespacePermissions *authorization.NamespacePermissions) *ProcessRepo
func (*ProcessRepo) CreateProcess ¶
func (r *ProcessRepo) CreateProcess(ctx context.Context, authInfo authorization.Info, message CreateProcessMessage) error
func (*ProcessRepo) GetProcess ¶
func (r *ProcessRepo) GetProcess(ctx context.Context, authInfo authorization.Info, processGUID string) (ProcessRecord, error)
func (*ProcessRepo) GetProcessByAppTypeAndSpace ¶
func (r *ProcessRepo) GetProcessByAppTypeAndSpace(ctx context.Context, authInfo authorization.Info, appGUID, processType, spaceGUID string) (ProcessRecord, error)
func (*ProcessRepo) ListProcesses ¶
func (r *ProcessRepo) ListProcesses(ctx context.Context, authInfo authorization.Info, message ListProcessesMessage) ([]ProcessRecord, error)
func (*ProcessRepo) PatchProcess ¶
func (r *ProcessRepo) PatchProcess(ctx context.Context, authInfo authorization.Info, message PatchProcessMessage) (ProcessRecord, error)
func (*ProcessRepo) ScaleProcess ¶
func (r *ProcessRepo) ScaleProcess(ctx context.Context, authInfo authorization.Info, scaleProcessMessage ScaleProcessMessage) (ProcessRecord, error)
type ProcessScaleValues ¶
type RoleRecord ¶
type RoleRepo ¶
type RoleRepo struct {
// contains filtered or unexported fields
}
func NewRoleRepo ¶
func NewRoleRepo(privilegedClient client.Client, userClientFactory UserK8sClientFactory, authorizedInChecker AuthorizedInChecker, rootNamespace string, roleMappings map[string]config.Role) *RoleRepo
func (*RoleRepo) CreateRole ¶
func (r *RoleRepo) CreateRole(ctx context.Context, authInfo authorization.Info, role CreateRoleMessage) (RoleRecord, error)
type RouteRecord ¶
type RouteRecord struct { GUID string SpaceGUID string Domain DomainRecord Host string Path string Protocol string Destinations []DestinationRecord Labels map[string]string Annotations map[string]string CreatedAt string UpdatedAt string }
func (RouteRecord) UpdateDomainRef ¶
func (r RouteRecord) UpdateDomainRef(d DomainRecord) RouteRecord
type RouteRepo ¶
type RouteRepo struct {
// contains filtered or unexported fields
}
func NewRouteRepo ¶
func NewRouteRepo( privilegedClient client.Client, namespaceRetriever NamespaceRetriever, userClientFactory UserK8sClientFactory, authPerms *authorization.NamespacePermissions, ) *RouteRepo
func (*RouteRepo) AddDestinationsToRoute ¶
func (f *RouteRepo) AddDestinationsToRoute(ctx context.Context, authInfo authorization.Info, message AddDestinationsToRouteMessage) (RouteRecord, error)
func (*RouteRepo) CreateRoute ¶
func (f *RouteRepo) CreateRoute(ctx context.Context, authInfo authorization.Info, message CreateRouteMessage) (RouteRecord, error)
func (*RouteRepo) DeleteRoute ¶
func (f *RouteRepo) DeleteRoute(ctx context.Context, authInfo authorization.Info, message DeleteRouteMessage) error
func (*RouteRepo) GetOrCreateRoute ¶
func (f *RouteRepo) GetOrCreateRoute(ctx context.Context, authInfo authorization.Info, message CreateRouteMessage) (RouteRecord, error)
func (*RouteRepo) GetRoute ¶
func (f *RouteRepo) GetRoute(ctx context.Context, authInfo authorization.Info, routeGUID string) (RouteRecord, error)
func (*RouteRepo) ListRoutes ¶
func (f *RouteRepo) ListRoutes(ctx context.Context, authInfo authorization.Info, message ListRoutesMessage) ([]RouteRecord, error)
func (*RouteRepo) ListRoutesForApp ¶
func (f *RouteRepo) ListRoutesForApp(ctx context.Context, authInfo authorization.Info, appGUID string, spaceGUID string) ([]RouteRecord, error)
type ScaleProcessMessage ¶
type ScaleProcessMessage struct { GUID string SpaceGUID string ProcessScaleValues }
type ServiceBindingRecord ¶
type ServiceBindingRepo ¶
type ServiceBindingRepo struct {
// contains filtered or unexported fields
}
func NewServiceBindingRepo ¶
func NewServiceBindingRepo( namespaceRetriever NamespaceRetriever, userClientFactory UserK8sClientFactory, namespacePermissions *authorization.NamespacePermissions, ) *ServiceBindingRepo
func (*ServiceBindingRepo) CreateServiceBinding ¶
func (r *ServiceBindingRepo) CreateServiceBinding(ctx context.Context, authInfo authorization.Info, message CreateServiceBindingMessage) (ServiceBindingRecord, error)
func (*ServiceBindingRepo) DeleteServiceBinding ¶
func (r *ServiceBindingRepo) DeleteServiceBinding(ctx context.Context, authInfo authorization.Info, guid string) error
func (*ServiceBindingRepo) ListServiceBindings ¶
func (r *ServiceBindingRepo) ListServiceBindings(ctx context.Context, authInfo authorization.Info, message ListServiceBindingsMessage) ([]ServiceBindingRecord, error)
func (*ServiceBindingRepo) ServiceBindingExists ¶
func (r *ServiceBindingRepo) ServiceBindingExists(ctx context.Context, authInfo authorization.Info, spaceGUID, appGUID, serviceInstanceGUID string) (bool, error)
type ServiceInstanceRecord ¶
type ServiceInstanceRepo ¶
type ServiceInstanceRepo struct {
// contains filtered or unexported fields
}
func NewServiceInstanceRepo ¶
func NewServiceInstanceRepo( namespaceRetriever NamespaceRetriever, userClientFactory UserK8sClientFactory, namespacePermissions *authorization.NamespacePermissions, ) *ServiceInstanceRepo
func (*ServiceInstanceRepo) CreateServiceInstance ¶
func (r *ServiceInstanceRepo) CreateServiceInstance(ctx context.Context, authInfo authorization.Info, message CreateServiceInstanceMessage) (ServiceInstanceRecord, error)
func (*ServiceInstanceRepo) DeleteServiceInstance ¶
func (r *ServiceInstanceRepo) DeleteServiceInstance(ctx context.Context, authInfo authorization.Info, message DeleteServiceInstanceMessage) error
func (*ServiceInstanceRepo) GetServiceInstance ¶
func (r *ServiceInstanceRepo) GetServiceInstance(ctx context.Context, authInfo authorization.Info, guid string) (ServiceInstanceRecord, error)
func (*ServiceInstanceRepo) ListServiceInstances ¶
func (r *ServiceInstanceRepo) ListServiceInstances(ctx context.Context, authInfo authorization.Info, message ListServiceInstanceMessage) ([]ServiceInstanceRecord, error)
type SpaceRecord ¶
type UnprivilegedClientFactory ¶
type UnprivilegedClientFactory struct {
// contains filtered or unexported fields
}
func NewUnprivilegedClientFactory ¶
func NewUnprivilegedClientFactory(config *rest.Config, mapper meta.RESTMapper) UnprivilegedClientFactory
func (UnprivilegedClientFactory) BuildClient ¶
func (f UnprivilegedClientFactory) BuildClient(authInfo authorization.Info) (client.WithWatch, error)
type UserK8sClientFactory ¶
type UserK8sClientFactory interface {
BuildClient(authorization.Info) (client.WithWatch, error)
}
Source Files ¶
- app_repository.go
- build_repository.go
- buildpack_repository.go
- domain_repository.go
- droplet_repository.go
- image_repository.go
- k8s_client.go
- namespace_retriever.go
- org_repository.go
- package_repository.go
- pod_repository.go
- process_repository.go
- role_repository.go
- route_repository.go
- service_binding_repository.go
- service_instance_repository.go
- shared.go
Click to show internal directories.
Click to hide internal directories.