Documentation
¶
Index ¶
- Variables
- type BindParameters
- type BrokerCatalog
- type Catalog
- type CatalogExternal
- type Config
- type Credentials
- type ProvisionParameters
- type S3Broker
- func (b *S3Broker) Bind(context context.Context, instanceID string, bindingID string, ...) (domain.Binding, error)
- func (b *S3Broker) Deprovision(context context.Context, instanceID string, details domain.DeprovisionDetails, ...) (domain.DeprovisionServiceSpec, error)
- func (b *S3Broker) GetBinding(ctx context.Context, instanceID, bindingID string, ...) (domain.GetBindingSpec, error)
- func (b *S3Broker) GetBucketURI(credentials Credentials) string
- func (b *S3Broker) GetInstance(ctx context.Context, instanceID string, details domain.FetchInstanceDetails) (domain.GetInstanceDetailsSpec, error)
- func (b *S3Broker) LastBindingOperation(ctx context.Context, instanceID, bindingID string, details domain.PollDetails) (domain.LastOperation, error)
- func (b *S3Broker) LastOperation(ctx context.Context, instanceID string, details domain.PollDetails) (domain.LastOperation, error)
- func (b *S3Broker) Provision(context context.Context, instanceID string, details domain.ProvisionDetails, ...) (domain.ProvisionedServiceSpec, error)
- func (b *S3Broker) Services(context context.Context) ([]brokerapi.Service, error)
- func (b *S3Broker) Unbind(context context.Context, instanceID, bindingID string, ...) (domain.UnbindSpec, error)
- func (b *S3Broker) Update(context context.Context, instanceID string, details domain.UpdateDetails, ...) (domain.UpdateServiceSpec, error)
- type S3Properties
- type Service
- type ServicePlan
- type UpdateParameters
Constants ¶
This section is empty.
Variables ¶
View Source
var (
ErrNoClientConfigured = errors.New("This broker is not configured to support binding to additional instances. Contact your Cloud Foundry operator for details.")
)
Functions ¶
This section is empty.
Types ¶
type BindParameters ¶
type BindParameters struct { // Set AdditionalInstances to bind credentials that have permission to // access multiple s3 buckets, not just one. This is useful when copying // files between buckets. The contents should be a list of service // instance names. AdditionalInstances []string `json:"additional_instances"` }
type BrokerCatalog ¶
type BrokerCatalog struct {
Services []Service `yaml:"services,omitempty"`
}
func (BrokerCatalog) FindService ¶
func (c BrokerCatalog) FindService(serviceID string) (service Service, found bool)
func (BrokerCatalog) FindServicePlan ¶
func (c BrokerCatalog) FindServicePlan(planID string) (plan ServicePlan, found bool)
func (BrokerCatalog) ListServicePlans ¶
func (c BrokerCatalog) ListServicePlans() []ServicePlan
func (BrokerCatalog) Validate ¶
func (c BrokerCatalog) Validate() error
type Catalog ¶
type Catalog interface { Validate() error FindService(serviceID string) (service Service, found bool) FindServicePlan(planID string) (plan ServicePlan, found bool) ListServicePlans() []ServicePlan }
type CatalogExternal ¶
type CatalogExternal struct {
Services []brokerapi.Service `json:"services"`
}
type Config ¶
type Config struct { Region string `yaml:"region"` Endpoint string `yaml:"endpoint"` InsecureSkipVerify bool `yaml:"insecure_skip_verify"` Provider string `yaml:"provider"` IamPath string `yaml:"iam_path"` UserPrefix string `yaml:"user_prefix"` PolicyPrefix string `yaml:"policy_prefix"` BucketPrefix string `yaml:"bucket_prefix"` AwsPartition string `yaml:"aws_partition"` AllowUserProvisionParameters bool `yaml:"allow_user_provision_parameters"` AllowUserUpdateParameters bool `yaml:"allow_user_update_parameters"` Catalog BrokerCatalog `yaml:"catalog"` }
type Credentials ¶
type Credentials struct { URI string `json:"uri"` InsecureSkipVerify bool `json:"insecure_skip_verify"` AccessKeyID string `json:"access_key_id"` SecretAccessKey string `json:"secret_access_key"` Region string `json:"region"` Bucket string `json:"bucket"` Endpoint string `json:"endpoint"` FIPSEndpoint string `json:"fips_endpoint"` AdditionalBuckets []string `json:"additional_buckets"` }
type ProvisionParameters ¶
type ProvisionParameters struct {
ObjectOwnership string `json:"object_ownership"`
}
type S3Broker ¶
type S3Broker struct {
// contains filtered or unexported fields
}
func (*S3Broker) Deprovision ¶
func (b *S3Broker) Deprovision( context context.Context, instanceID string, details domain.DeprovisionDetails, asyncAllowed bool, ) (domain.DeprovisionServiceSpec, error)
func (*S3Broker) GetBinding ¶
func (b *S3Broker) GetBinding( ctx context.Context, instanceID, bindingID string, details domain.FetchBindingDetails, ) (domain.GetBindingSpec, error)
func (*S3Broker) GetBucketURI ¶
func (b *S3Broker) GetBucketURI(credentials Credentials) string
func (*S3Broker) GetInstance ¶
func (b *S3Broker) GetInstance( ctx context.Context, instanceID string, details domain.FetchInstanceDetails, ) (domain.GetInstanceDetailsSpec, error)
func (*S3Broker) LastBindingOperation ¶
func (b *S3Broker) LastBindingOperation( ctx context.Context, instanceID, bindingID string, details domain.PollDetails, ) (domain.LastOperation, error)
func (*S3Broker) LastOperation ¶
func (b *S3Broker) LastOperation( ctx context.Context, instanceID string, details domain.PollDetails, ) (domain.LastOperation, error)
func (*S3Broker) Provision ¶
func (b *S3Broker) Provision( context context.Context, instanceID string, details domain.ProvisionDetails, asyncAllowed bool, ) (domain.ProvisionedServiceSpec, error)
type S3Properties ¶
type S3Properties struct { IamPolicy string `yaml:"iam_policy,omitempty"` BucketPolicy string `yaml:"bucket_policy,omitempty"` Encryption string `yaml:"encryption,omitempty"` }
func (S3Properties) Validate ¶
func (eq S3Properties) Validate() error
type Service ¶
type Service struct { ID string `yaml:"id"` Name string `yaml:"name"` Description string `yaml:"description"` Bindable bool `yaml:"bindable"` Tags []string `yaml:"tags,omitempty"` PlanUpdatable bool `yaml:"plan_updateable"` Plans []ServicePlan `yaml:"plans"` Requires []brokerapi.RequiredPermission `yaml:"requires,omitempty"` Metadata *brokerapi.ServiceMetadata `yaml:"metadata,omitempty"` DashboardClient *brokerapi.ServiceDashboardClient `yaml:"dashboard_client,omitempty"` }
type ServicePlan ¶
type ServicePlan struct { ID string `yaml:"id"` Name string `yaml:"name"` Description string `yaml:"description"` Free bool `yaml:"free"` Metadata *brokerapi.ServicePlanMetadata `yaml:"metadata,omitempty"` PlanDeletable bool `yaml:"deletable,omitempty"` S3Properties S3Properties `yaml:"s3_properties,omitempty"` }
func (ServicePlan) Validate ¶
func (sp ServicePlan) Validate() error
type UpdateParameters ¶
type UpdateParameters struct {
ApplyImmediately bool `json:"apply_immediately"`
}
Click to show internal directories.
Click to hide internal directories.