Documentation ¶
Index ¶
- func Export(org, space string, service Service, instance *cf.ServiceInstance) flow.StepFunc
- func Import(org, space string, service Service, instance *cf.ServiceInstance, ...) flow.StepFunc
- func IsCCDBTypeMigrator(configType string) bool
- func NewExportSequence(org, space string, service Service, instance *cf.ServiceInstance, ...) flow.Flow
- func NewImportSequence(org, space string, service Service, instance *cf.ServiceInstance, ...) flow.Flow
- func SetCloudControllerDatabaseCredentials(e exec.Executor, cfg *DatabaseConfig, om config.OpsManager) flow.StepFunc
- type ClientHolder
- type CloudControllerRepositoryFactory
- type CloudControllerServiceFactory
- type Config
- type DatabaseConfig
- type DatabaseFactory
- type DefaultCloudControllerService
- func (m DefaultCloudControllerService) Create(org, space string, instance *cf.ServiceInstance, encryptionKey string) error
- func (m DefaultCloudControllerService) CreateApp(org, space, name string) (string, error)
- func (m DefaultCloudControllerService) CreateServiceBinding(binding *cf.ServiceBinding, appGUID string, encryptionKey string) error
- func (m DefaultCloudControllerService) CreateServiceKey(si cf.ServiceInstance, key cf.ServiceKey) error
- func (m DefaultCloudControllerService) Delete(org, space string, instance *cf.ServiceInstance) error
- func (m DefaultCloudControllerService) DownloadManifest(org, space, appName string) (cf.Application, error)
- func (m DefaultCloudControllerService) FindAppByGUID(guid string) (string, error)
- func (m DefaultCloudControllerService) ServiceInstanceExists(org, space, instanceName string) (bool, error)
- type DefaultCloudControllerServiceFactory
- type DefaultManifestExporter
- type ManifestExporter
- type Migrator
- type Service
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func IsCCDBTypeMigrator ¶
func NewExportSequence ¶
func NewExportSequence(org, space string, service Service, instance *cf.ServiceInstance, executor exec.Executor, manager config.OpsManager, controller *DatabaseConfig) flow.Flow
func NewImportSequence ¶
func NewImportSequence(org, space string, service Service, instance *cf.ServiceInstance, encryptionKey string, executor exec.Executor, manager config.OpsManager, controller *DatabaseConfig) flow.Flow
func SetCloudControllerDatabaseCredentials ¶
func SetCloudControllerDatabaseCredentials(e exec.Executor, cfg *DatabaseConfig, om config.OpsManager) flow.StepFunc
Types ¶
type ClientHolder ¶
type CloudControllerRepositoryFactory ¶
type CloudControllerRepositoryFactory interface {
NewCCDB(bool) (db.Repository, error)
}
type Config ¶
type Config struct { SourceCloudControllerDatabase DatabaseConfig `yaml:"source_ccdb"` TargetCloudControllerDatabase DatabaseConfig `yaml:"target_ccdb"` }
type DatabaseConfig ¶
type DatabaseConfig struct { Host string `yaml:"db_host"` Username string `yaml:"db_username"` Password string `yaml:"db_password"` EncryptionKey string `yaml:"db_encryption_key"` SSHHost string `yaml:"ssh_host"` SSHUsername string `yaml:"ssh_username"` SSHPassword string `yaml:"ssh_password"` SSHPrivateKey string `yaml:"ssh_private_key"` TunnelRequired bool `yaml:"ssh_tunnel"` }
func (DatabaseConfig) IsSet ¶
func (c DatabaseConfig) IsSet() bool
func (DatabaseConfig) Validate ¶
func (c DatabaseConfig) Validate() error
type DatabaseFactory ¶
type DatabaseFactory struct {
// contains filtered or unexported fields
}
func NewDatabaseFactory ¶
func NewDatabaseFactory(cfg *Config) DatabaseFactory
func (DatabaseFactory) NewCCDB ¶
func (f DatabaseFactory) NewCCDB(isExport bool) (db.Repository, error)
type DefaultCloudControllerService ¶
type DefaultCloudControllerService struct { Client cf.Client Database db.Repository ManifestExporter ManifestExporter }
func NewCloudControllerService ¶
func NewCloudControllerService(db db.Repository, cf cf.Client, manifestExporter ManifestExporter) DefaultCloudControllerService
func (DefaultCloudControllerService) Create ¶
func (m DefaultCloudControllerService) Create(org, space string, instance *cf.ServiceInstance, encryptionKey string) error
func (DefaultCloudControllerService) CreateApp ¶
func (m DefaultCloudControllerService) CreateApp(org, space, name string) (string, error)
func (DefaultCloudControllerService) CreateServiceBinding ¶
func (m DefaultCloudControllerService) CreateServiceBinding(binding *cf.ServiceBinding, appGUID string, encryptionKey string) error
func (DefaultCloudControllerService) CreateServiceKey ¶
func (m DefaultCloudControllerService) CreateServiceKey(si cf.ServiceInstance, key cf.ServiceKey) error
func (DefaultCloudControllerService) Delete ¶
func (m DefaultCloudControllerService) Delete(org, space string, instance *cf.ServiceInstance) error
func (DefaultCloudControllerService) DownloadManifest ¶
func (m DefaultCloudControllerService) DownloadManifest(org, space, appName string) (cf.Application, error)
func (DefaultCloudControllerService) FindAppByGUID ¶
func (m DefaultCloudControllerService) FindAppByGUID(guid string) (string, error)
func (DefaultCloudControllerService) ServiceInstanceExists ¶
func (m DefaultCloudControllerService) ServiceInstanceExists(org, space, instanceName string) (bool, error)
type DefaultCloudControllerServiceFactory ¶
type DefaultCloudControllerServiceFactory struct {
// contains filtered or unexported fields
}
func NewCloudControllerServiceFactory ¶
func NewCloudControllerServiceFactory(h ClientHolder, manifestExporter ManifestExporter) DefaultCloudControllerServiceFactory
func (DefaultCloudControllerServiceFactory) NewCloudControllerService ¶
func (f DefaultCloudControllerServiceFactory) NewCloudControllerService(cfg *Config, isExport bool) (Service, error)
type DefaultManifestExporter ¶
type DefaultManifestExporter struct {
// contains filtered or unexported fields
}
func NewManifestExporter ¶
func NewManifestExporter(cfg *config.Config, h ClientHolder) *DefaultManifestExporter
func (*DefaultManifestExporter) ExportAppManifest ¶
func (m *DefaultManifestExporter) ExportAppManifest(org cfclient.Org, space cfclient.Space, app cfclient.App) (cf.Application, error)
type ManifestExporter ¶
type ManifestExporter interface {
ExportAppManifest(org cfclient.Org, space cfclient.Space, app cfclient.App) (cf.Application, error)
}
type Migrator ¶
type Migrator struct {
// contains filtered or unexported fields
}
func NewMigrator ¶
type Service ¶
type Service interface { Create(org, space string, instance *cf.ServiceInstance, encryptionKey string) error Delete(org, space string, instance *cf.ServiceInstance) error ServiceInstanceExists(org, space, name string) (bool, error) CreateServiceKey(si cf.ServiceInstance, key cf.ServiceKey) error CreateApp(org, space, name string) (string, error) CreateServiceBinding(binding *cf.ServiceBinding, appGUID string, encryptionKey string) error FindAppByGUID(guid string) (string, error) DownloadManifest(org, space, appName string) (cf.Application, error) }
Source Files ¶
Click to show internal directories.
Click to hide internal directories.