api

package
v0.0.0-...-0e59c02 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 27, 2018 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

View Source
const (
	StatusRunning   = "running"
	StatusSucceeded = "succeeded"
	StatusFailed    = "failed"
)
View Source
const (
	EnsureAvailabilityStatusUnstarted = "unstarted"
	EnsureAvailabilityStatusPending   = "pending"
	EnsureAvailabilityStatusComplete  = "complete"
	EnsureAvailabilityStatusUnknown   = "unknown"
)

Variables

This section is empty.

Functions

func ValidateStatusOK

func ValidateStatusOK(resp *http.Response) error

Types

type AZConfiguration

type AZConfiguration struct {
	AvailabilityZones json.RawMessage `json:"availability_zones,omitempty"`
}

type ActivateCertificateAuthorityInput

type ActivateCertificateAuthorityInput struct {
	GUID string
}

type AvailableProductsInput

type AvailableProductsInput struct {
	ProductName    string
	ProductVersion string
}

type AvailableProductsOutput

type AvailableProductsOutput struct {
	ProductsList []ProductInfo
}

type AvailableProductsService

type AvailableProductsService struct {
	// contains filtered or unexported fields
}

func NewAvailableProductsService

func NewAvailableProductsService(client httpClient, progress progress, liveWriter liveWriter) AvailableProductsService

func (AvailableProductsService) CheckProductAvailability

func (ap AvailableProductsService) CheckProductAvailability(productName string, productVersion string) (bool, error)

func (AvailableProductsService) Delete

func (AvailableProductsService) List

func (AvailableProductsService) Upload

type BoshFormService

type BoshFormService struct {
	// contains filtered or unexported fields
}

func NewBoshFormService

func NewBoshFormService(client httpClient) BoshFormService

func (BoshFormService) AvailabilityZones

func (bs BoshFormService) AvailabilityZones() (map[string]string, error)

func (BoshFormService) GetForm

func (bs BoshFormService) GetForm(path string) (Form, error)

func (BoshFormService) Networks

func (bs BoshFormService) Networks() (map[string]string, error)

func (BoshFormService) PostForm

func (bs BoshFormService) PostForm(input PostFormInput) error

type CA

type CA struct {
	GUID      string `json:"guid"`
	Issuer    string `json:"issuer"`
	CreatedOn string `json:"created_on"`
	ExpiresOn string `json:"expires_on"`
	Active    bool   `json:"active"`
	CertPEM   string `json:"cert_pem"`
}

type CertificateAuthoritiesOutput

type CertificateAuthoritiesOutput struct {
	CAs []CA `json:"certificate_authorities"`
}

type CertificateAuthoritiesService

type CertificateAuthoritiesService struct {
	// contains filtered or unexported fields
}

func NewCertificateAuthoritiesService

func NewCertificateAuthoritiesService(client httpClient) CertificateAuthoritiesService

func (CertificateAuthoritiesService) Activate

func (CertificateAuthoritiesService) Create

func (CertificateAuthoritiesService) Delete

func (CertificateAuthoritiesService) Generate

func (c CertificateAuthoritiesService) Generate() (CA, error)

func (CertificateAuthoritiesService) List

func (CertificateAuthoritiesService) Regenerate

func (c CertificateAuthoritiesService) Regenerate() error

type CertificateAuthorityInput

type CertificateAuthorityInput struct {
	CertPem       string `json:"cert_pem"`
	PrivateKeyPem string `json:"private_key_pem"`
}

type CertificatesService

type CertificatesService struct {
	// contains filtered or unexported fields
}

func NewCertificatesService

func NewCertificatesService(client httpClient) CertificatesService

func (CertificatesService) Generate

func (c CertificatesService) Generate(domains string) (string, error)

type ConfigurationRequest

type ConfigurationRequest struct {
	Method        string
	URL           string
	Configuration string
}

type CreateVMExtension

type CreateVMExtension struct {
	Name            string          `json:"name"`
	CloudProperties json.RawMessage `json:"cloud_properties"`
}

type Credential

type Credential struct {
	Type  string            `json:"type"`
	Value map[string]string `json:"value"`
}

type CredentialOutput

type CredentialOutput struct {
	Credential Credential `json:"credential"`
}

type CredentialReferencesOutput

type CredentialReferencesOutput struct {
	Credentials []string `json:"credentials"`
}

type CredentialReferencesService

type CredentialReferencesService struct {
	// contains filtered or unexported fields
}

func NewCredentialReferencesService

func NewCredentialReferencesService(client httpClient, progress progress) CredentialReferencesService

func (CredentialReferencesService) List

type CredentialsService

type CredentialsService struct {
	// contains filtered or unexported fields
}

func NewCredentialsService

func NewCredentialsService(client httpClient, progress progress) CredentialsService

func (CredentialsService) Fetch

func (cr CredentialsService) Fetch(deployedGUID, credential string) (CredentialOutput, error)

type DashboardService

type DashboardService struct {
	// contains filtered or unexported fields
}

func NewDashboardService

func NewDashboardService(client httpClient) DashboardService

func (DashboardService) GetInstallForm

func (ds DashboardService) GetInstallForm() (Form, error)

func (DashboardService) GetRevertForm

func (ds DashboardService) GetRevertForm() (Form, error)

func (DashboardService) PostInstallForm

func (ds DashboardService) PostInstallForm(input PostFormInput) error

type DeleteCertificateAuthorityInput

type DeleteCertificateAuthorityInput struct {
	GUID string
}

type DeployedProductOutput

type DeployedProductOutput struct {
	Type string
	GUID string
}

type DeployedProductsService

type DeployedProductsService struct {
	// contains filtered or unexported fields
}

func NewDeployedProductsService

func NewDeployedProductsService(client httpClient) DeployedProductsService

func (DeployedProductsService) List

func (DeployedProductsService) Manifest

func (s DeployedProductsService) Manifest(guid string) (string, error)

type DiagnosticProduct

type DiagnosticProduct struct {
	Name     string `json:"name"`
	Version  string `json:"version"`
	Stemcell string `json:"stemcell,omitempty"`
}

type DiagnosticReport

type DiagnosticReport struct {
	InfrastructureType string `json:"infrastructure_type"`
	Stemcells          []string
	StagedProducts     []DiagnosticProduct
	DeployedProducts   []DiagnosticProduct
}

type DiagnosticReportUnavailable

type DiagnosticReportUnavailable struct{}

func (DiagnosticReportUnavailable) Error

type DiagnosticService

type DiagnosticService struct {
	// contains filtered or unexported fields
}

func NewDiagnosticService

func NewDiagnosticService(client httpClient) DiagnosticService

func (DiagnosticService) Report

func (ds DiagnosticService) Report() (DiagnosticReport, error)

type DirectorProperties

type DirectorProperties struct {
	IAASConfiguration     json.RawMessage `json:"iaas_configuration,omitempty"`
	DirectorConfiguration json.RawMessage `json:"director_configuration,omitempty"`
	SecurityConfiguration json.RawMessage `json:"security_configuration,omitempty"`
	SyslogConfiguration   json.RawMessage `json:"syslog_configuration,omitempty"`
}

type DirectorService

type DirectorService struct {
	// contains filtered or unexported fields
}

func NewDirectorService

func NewDirectorService(client httpClient) DirectorService

func (DirectorService) AZConfiguration

func (d DirectorService) AZConfiguration(input AZConfiguration) error

func (DirectorService) NetworkAndAZ

func (d DirectorService) NetworkAndAZ(input NetworkAndAZConfiguration) error

func (DirectorService) NetworksConfiguration

func (d DirectorService) NetworksConfiguration(input json.RawMessage) error

func (DirectorService) Properties

func (d DirectorService) Properties(input DirectorProperties) error

type Disk

type Disk struct {
	Size string `json:"size_mb"`
}

type EnsureAvailabilityInput

type EnsureAvailabilityInput struct{}

type EnsureAvailabilityOutput

type EnsureAvailabilityOutput struct {
	Status string
}

type Errand

type Errand struct {
	Name       string      `json:"name"`
	PostDeploy interface{} `json:"post_deploy,omitempty"`
	PreDelete  interface{} `json:"pre_delete,omitempty"`
}

type ErrandsListOutput

type ErrandsListOutput struct {
	Errands []Errand `json:"errands"`
}

type ErrandsService

type ErrandsService struct {
	Client httpClient
}

func NewErrandsService

func NewErrandsService(client httpClient) ErrandsService

func (ErrandsService) List

func (es ErrandsService) List(productID string) (ErrandsListOutput, error)

func (ErrandsService) SetState

func (es ErrandsService) SetState(productID string, errandName string, postDeployState interface{}, preDeleteState interface{}) error

type Form

type Form struct {
	Action            string
	AuthenticityToken string
	RailsMethod       string
}

type ImportInstallationInput

type ImportInstallationInput struct {
	ContentLength   int64
	Installation    io.Reader
	ContentType     string
	PollingInterval int
}

type InstallationAssetService

type InstallationAssetService struct {
	// contains filtered or unexported fields
}

func NewInstallationAssetService

func NewInstallationAssetService(client httpClient, progress progress, liveWriter liveWriter) InstallationAssetService

func (InstallationAssetService) Delete

func (InstallationAssetService) Export

func (ia InstallationAssetService) Export(outputFile string, pollingInterval int) error

func (InstallationAssetService) Import

type InstallationsService

type InstallationsService struct {
	// contains filtered or unexported fields
}

func NewInstallationsService

func NewInstallationsService(client httpClient) InstallationsService

func (InstallationsService) ListInstallations

func (is InstallationsService) ListInstallations() ([]InstallationsServiceOutput, error)

func (InstallationsService) Logs

func (InstallationsService) RunningInstallation

func (is InstallationsService) RunningInstallation() (InstallationsServiceOutput, error)

func (InstallationsService) Status

func (InstallationsService) Trigger

func (is InstallationsService) Trigger(ignoreWarnings bool, deployProducts bool) (InstallationsServiceOutput, error)

type InstallationsServiceOutput

type InstallationsServiceOutput struct {
	ID         int
	Status     string
	Logs       string
	StartedAt  *time.Time `json:"started_at"`
	FinishedAt *time.Time `json:"finished_at"`
	UserName   string     `json:"user_name"`
}

type InstanceType

type InstanceType struct {
	ID string `json:"id"`
}

type Job

type Job struct {
	GUID string
	Name string
}

type JobProperties

type JobProperties struct {
	Instances              interface{}  `json:"instances"`
	PersistentDisk         *Disk        `json:"persistent_disk,omitempty"`
	InstanceType           InstanceType `json:"instance_type"`
	InternetConnected      *bool        `json:"internet_connected,omitempty"`
	LBNames                []string     `json:"elb_names"`
	NSXSecurityGroups      []string     `json:"nsx_security_groups,omitempty"`
	NSXLBS                 []NSXLB      `json:"nsx_lbs,omitempty"`
	FloatingIPs            string       `json:"floating_ips,omitempty"`
	AdditionalVMExtensions []string     `json:"additional_vm_extensions,omitempty"`
}

type JobsService

type JobsService struct {
	// contains filtered or unexported fields
}

func NewJobsService

func NewJobsService(client httpClient) JobsService

func (JobsService) ConfigureJob

func (j JobsService) ConfigureJob(productGUID, jobGUID string, jobProperties JobProperties) error

func (JobsService) GetExistingJobConfig

func (j JobsService) GetExistingJobConfig(productGUID, jobGUID string) (JobProperties, error)

func (JobsService) Jobs

func (j JobsService) Jobs(productGUID string) (map[string]string, error)

type NSXLB

type NSXLB struct {
	EdgeName      string `json:"edge_name"`
	PoolName      string `json:"pool_name"`
	SecurityGroup string `json:"security_group"`
	Port          string `json:"port"`
}

type NetworkAndAZConfiguration

type NetworkAndAZConfiguration struct {
	NetworkAZ json.RawMessage `json:"network_and_az,omitempty"`
}

type PendingChangesOutput

type PendingChangesOutput struct {
	ChangeList []ProductChange `json:"product_changes"`
}

type PendingChangesService

type PendingChangesService struct {
	// contains filtered or unexported fields
}

func NewPendingChangesService

func NewPendingChangesService(client httpClient) PendingChangesService

func (PendingChangesService) List

type PostFormInput

type PostFormInput struct {
	Form
	EncodedPayload string
}

type ProductChange

type ProductChange struct {
	Product string   `json:"guid"`
	Errands []Errand `json:"errands"`
	Action  string   `json:"action"`
}

type ProductInfo

type ProductInfo struct {
	Name    string `json:"name"`
	Version string `json:"product_version"`
}

type ProductsConfigurationInput

type ProductsConfigurationInput struct {
	GUID          string
	Configuration string
	Network       string
}

type RequestService

type RequestService struct {
	// contains filtered or unexported fields
}

func NewRequestService

func NewRequestService(client httpClient) RequestService

func (RequestService) Invoke

type RequestServiceInvokeInput

type RequestServiceInvokeInput struct {
	Path    string
	Method  string
	Data    io.Reader
	Headers http.Header
}

type RequestServiceInvokeOutput

type RequestServiceInvokeOutput struct {
	StatusCode int
	Headers    http.Header
	Body       io.Reader
}

type SecurityService

type SecurityService struct {
	// contains filtered or unexported fields
}

func NewSecurityService

func NewSecurityService(client httpClient) SecurityService

func (SecurityService) FetchRootCACert

func (s SecurityService) FetchRootCACert() (string, error)

type SetupInput

type SetupInput struct {
	IdentityProvider                 string
	AdminUserName                    string
	AdminPassword                    string
	AdminPasswordConfirmation        string
	DecryptionPassphrase             string
	DecryptionPassphraseConfirmation string
	EULAAccepted                     bool
	HTTPProxyURL                     string
	HTTPSProxyURL                    string
	NoProxy                          string
}

type SetupOutput

type SetupOutput struct{}

type SetupService

type SetupService struct {
	// contains filtered or unexported fields
}

func NewSetupService

func NewSetupService(client httpClient) SetupService

func (SetupService) EnsureAvailability

func (ss SetupService) EnsureAvailability(input EnsureAvailabilityInput) (EnsureAvailabilityOutput, error)

func (SetupService) Setup

func (ss SetupService) Setup(input SetupInput) (SetupOutput, error)

type StageProductInput

type StageProductInput struct {
	ProductName    string `json:"name"`
	ProductVersion string `json:"product_version"`
}

type StagedProduct

type StagedProduct struct {
	GUID string
	Type string
}

type StagedProductsFindOutput

type StagedProductsFindOutput struct {
	Product StagedProduct
}

type StagedProductsOutput

type StagedProductsOutput struct {
	Products []StagedProduct
}

type StagedProductsService

type StagedProductsService struct {
	// contains filtered or unexported fields
}

func NewStagedProductsService

func NewStagedProductsService(client httpClient) StagedProductsService

func (StagedProductsService) Configure

func (StagedProductsService) Find

func (StagedProductsService) List

func (StagedProductsService) Manifest

func (p StagedProductsService) Manifest(guid string) (string, error)

func (StagedProductsService) Stage

func (p StagedProductsService) Stage(input StageProductInput, deployedGUID string) error

func (StagedProductsService) Unstage

type StemcellUploadInput

type StemcellUploadInput struct {
	ContentLength int64
	Stemcell      io.Reader
	ContentType   string
}

type StemcellUploadOutput

type StemcellUploadOutput struct{}

type UnstageProductInput

type UnstageProductInput struct {
	ProductName string `json:"name"`
}

type UpgradeRequest

type UpgradeRequest struct {
	ToVersion string `json:"to_version"`
}

type UploadProductInput

type UploadProductInput struct {
	ContentLength   int64
	Product         io.Reader
	ContentType     string
	PollingInterval int
}

type UploadProductOutput

type UploadProductOutput struct{}

type UploadStemcellService

type UploadStemcellService struct {
	// contains filtered or unexported fields
}

func NewUploadStemcellService

func NewUploadStemcellService(client httpClient, progress progress) UploadStemcellService

func (UploadStemcellService) Upload

type VMExtensionInput

type VMExtensionInput struct {
	Name            string `json:"name"`
	CloudProperties string `json:"cloud_properties"`
}

type VMExtensionsService

type VMExtensionsService struct {
	// contains filtered or unexported fields
}

func NewVMExtensionsService

func NewVMExtensionsService(client httpClient) VMExtensionsService

func (VMExtensionsService) Create

Directories

Path Synopsis
Code generated by counterfeiter.
Code generated by counterfeiter.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL