Documentation
¶
Index ¶
- func NewKubeStore(configMapKey string) store.StoreInterface
- type ExecOptions
- type KubeStore
- func (k *KubeStore) CheckCertificateReadiness(blockName, envId string) (bool, *utilsGoServer.Error)
- func (k *KubeStore) CreateEnvironment(env *types.Environment) *utilsGoServer.Error
- func (k *KubeStore) DeleteBlock(name, envId string) *utilsGoServer.Error
- func (k *KubeStore) DeleteCustomDomainNames(envId, blockName, kintoHost string) *utilsGoServer.Error
- func (k *KubeStore) DeleteEnvironment(id string) *utilsGoServer.Error
- func (k *KubeStore) DisablePublicURL(envId, blockName string) *utilsGoServer.Error
- func (k *KubeStore) DoesCustomDomainExistInStore(host string) (bool, *utilsGoServer.Error)
- func (k *KubeStore) EnablePublicURL(envId, blockName string, protocol pkgTypes.RunConfig_Protocol, hosts ...string) *utilsGoServer.Error
- func (k *KubeStore) ExecCommandInContainerWithFullOutput(namespace, podName, containerName string, cmd ...string) (string, string, error)
- func (k *KubeStore) ExecWithOptions(options ExecOptions) (string, string, error)
- func (k *KubeStore) GetBlock(name, envId string) (*pkgtypes.Block, *utilsGoServer.Error)
- func (k *KubeStore) GetBlockHeathState(blockName, envId string, latestSuccessfulRelease *pkgTypes.Release) (pkgTypes.BlockStatus_State, error)
- func (k *KubeStore) GetBlocks(envId string) ([]*pkgtypes.Block, *utilsGoServer.Error)
- func (k *KubeStore) GetBlocksMetrics(name, envId string) (*types.BlocksMetrics, *utilsGoServer.Error)
- func (k *KubeStore) GetEnvironment(envId string) (*types.Environment, *utilsGoServer.Error)
- func (k *KubeStore) GetEnvironments() (*types.Environments, *utilsGoServer.Error)
- func (k *KubeStore) KillBlockInstance(id, envId string) *utilsGoServer.Error
- func (k *KubeStore) StartChiselService(ctx context.Context, envId, blockNameToTeleport string) (*types.TeleportServiceData, *utilsGoServer.Error)
- func (k *KubeStore) StopChiselService(envId, blockNameTeleported string) *utilsGoServer.Error
- func (k *KubeStore) UpdateEnvironment(env *types.Environment) *utilsGoServer.Error
- func (k *KubeStore) UpsertBlock(block *pkgtypes.Block) *utilsGoServer.Error
- func (k *KubeStore) UpsertCustomDomainNames(envId, blockName string, protocol pkgTypes.RunConfig_Protocol, ...) *utilsGoServer.Error
- func (k *KubeStore) WatchBlockReleaseStatus(blockName, envId string, ctx context.Context, ...) *utilsGoServer.Error
- func (k *KubeStore) WatchConsoleLogs(blockName, envId string, ctx context.Context, logsChan chan *types.ConsoleLog) *utilsGoServer.Error
- func (k *KubeStore) WatchJobsStatus(blockName, envId string, ctx context.Context, ...) *utilsGoServer.Error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewKubeStore ¶
func NewKubeStore(configMapKey string) store.StoreInterface
Types ¶
type ExecOptions ¶
type ExecOptions struct { Command []string Namespace string PodName string ContainerName string Stdin io.Reader CaptureStdout bool CaptureStderr bool // If false, whitespace in std{err,out} will be removed. PreserveWhitespace bool }
ExecOptions passed to ExecWithOptions
type KubeStore ¶
type KubeStore struct {
// contains filtered or unexported fields
}
func (*KubeStore) CheckCertificateReadiness ¶
func (k *KubeStore) CheckCertificateReadiness(blockName, envId string) (bool, *utilsGoServer.Error)
func (*KubeStore) CreateEnvironment ¶
func (k *KubeStore) CreateEnvironment(env *types.Environment) *utilsGoServer.Error
func (*KubeStore) DeleteBlock ¶
func (k *KubeStore) DeleteBlock(name, envId string) *utilsGoServer.Error
func (*KubeStore) DeleteCustomDomainNames ¶
func (k *KubeStore) DeleteCustomDomainNames(envId, blockName, kintoHost string) *utilsGoServer.Error
Delete the resources created for custom domain name - Ingress and Certificate - Don't delete the issuer since it can be used later - Update the proxless annotation on the kubernetes service to only contains the `kintoHost` - `kintoHost` must be empty if the kintohub service is deleted
func (*KubeStore) DeleteEnvironment ¶
func (k *KubeStore) DeleteEnvironment(id string) *utilsGoServer.Error
func (*KubeStore) DisablePublicURL ¶
func (k *KubeStore) DisablePublicURL(envId, blockName string) *utilsGoServer.Error
func (*KubeStore) DoesCustomDomainExistInStore ¶
func (k *KubeStore) DoesCustomDomainExistInStore(host string) (bool, *utilsGoServer.Error)
func (*KubeStore) EnablePublicURL ¶
func (k *KubeStore) EnablePublicURL( envId, blockName string, protocol pkgTypes.RunConfig_Protocol, hosts ...string) *utilsGoServer.Error
func (*KubeStore) ExecCommandInContainerWithFullOutput ¶
func (*KubeStore) ExecWithOptions ¶
func (k *KubeStore) ExecWithOptions(options ExecOptions) (string, string, error)
func (*KubeStore) GetBlockHeathState ¶
func (*KubeStore) GetBlocksMetrics ¶
func (k *KubeStore) GetBlocksMetrics(name, envId string) (*types.BlocksMetrics, *utilsGoServer.Error)
Collects resource requests, usage and storage information for all blocks in an environment or if provide optional blockName, the specific metrics of that block only.
func (*KubeStore) GetEnvironment ¶
func (k *KubeStore) GetEnvironment(envId string) (*types.Environment, *utilsGoServer.Error)
func (*KubeStore) GetEnvironments ¶
func (k *KubeStore) GetEnvironments() (*types.Environments, *utilsGoServer.Error)
func (*KubeStore) KillBlockInstance ¶
func (k *KubeStore) KillBlockInstance(id, envId string) *utilsGoServer.Error
func (*KubeStore) StartChiselService ¶
func (k *KubeStore) StartChiselService( ctx context.Context, envId, blockNameToTeleport string) (*types.TeleportServiceData, *utilsGoServer.Error)
Start chisel and configure it for `access` (proxy from local to remote) or `teleport` (proxy from remote to local) blockNameToTeleport - if empty, does not `teleport` anything the k8s service `blockNameToTeleport` will be modified to target chisel TODO handle the teleport differently, this is super confusing
func (*KubeStore) StopChiselService ¶
func (k *KubeStore) StopChiselService(envId, blockNameTeleported string) *utilsGoServer.Error
Stop chisel blockNameTeleported - if empty, does not do anything the k8s service `blockNameTeleported` will be modified to target the user app (it was targetting chisel) TODO handle the teleport differently, this is super confusing
func (*KubeStore) UpdateEnvironment ¶
func (k *KubeStore) UpdateEnvironment(env *types.Environment) *utilsGoServer.Error
func (*KubeStore) UpsertBlock ¶
func (k *KubeStore) UpsertBlock(block *pkgtypes.Block) *utilsGoServer.Error
func (*KubeStore) UpsertCustomDomainNames ¶
func (k *KubeStore) UpsertCustomDomainNames( envId, blockName string, protocol pkgTypes.RunConfig_Protocol, kintoHost string, domainNames ...string) *utilsGoServer.Error
func (*KubeStore) WatchBlockReleaseStatus ¶
func (k *KubeStore) WatchBlockReleaseStatus(blockName, envId string, ctx context.Context, statusChan chan *types.ReleasesStatus) *utilsGoServer.Error
func (*KubeStore) WatchConsoleLogs ¶
func (k *KubeStore) WatchConsoleLogs(blockName, envId string, ctx context.Context, logsChan chan *types.ConsoleLog) *utilsGoServer.Error
Listens to console logs to ALL instances of a specific block name in an environment Even if there are no blocks, new blocks or removed blocks - it will continue to observe and aggregate logs from each pod related to the blockName. This allows the client to listen pre-post deployment and wait for desired messages