appcloud

package
v0.2.2 Latest Latest
Warning

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

Go to latest
Published: Jan 6, 2022 License: Apache-2.0 Imports: 11 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

View Source
const (
	StatusSent      = "SENT"
	StatusConfirmed = "CONFIRMED"
)

These are the different statuses an invitation can have.

Variables

This section is empty.

Functions

This section is empty.

Types

type Backup

type Backup struct {
	Metadata CFMetadata `json:"metadata"`
	Entity   struct {
		Status   string    `json:"status"`
		Restores []Restore `json:"restores"`
	} `json:"entity"`
}

Backup is a service instance backup.

type BackupResponse

type BackupResponse struct {
	Backup
	ServerResponseError
}

BackupResponse is the response from the server from a create backup call.

type BackupsResponse

type BackupsResponse struct {
	Resources []Backup `json:"resources"`
	ServerResponsePagination
	ServerResponseError
}

BackupsResponse is the response of the server to a get backups call.

type BillingAccount

type BillingAccount struct {
	Metadata struct {
		GUID string `json:"guid"`
	} `json:"metadata"`
}

BillingAccount is an entity of the Swisscom Application Cloud which handles billing.

type BillingAccountsResponse added in v0.2.1

type BillingAccountsResponse struct {
	BillingAccounts []BillingAccount `json:"resources"`
	ServerResponseError
}

BillingAccountResponse is a response from the server to a billing account request.

type CFMetadata

type CFMetadata struct {
	GUID      string    `json:"guid"`
	URL       string    `json:"url"`
	CreatedAt time.Time `json:"created_at"`
	UpdatedAt time.Time `json:"updated_at"`
}

CFMetadata is a set of data any Cloud Foundry entity has.

type Domain

type Domain struct {
	Metadata CFMetadata `json:"metadata"`
	Entity   struct {
		Name string `json:"name"`
	} `json:"entity"`
}

Domain is a Cloud Foundry domain.

type DomainsResponse

type DomainsResponse struct {
	Resources []Domain `json:"resources"`
	ServerResponsePagination
	ServerResponseError
}

DomainsResponse is a response from the server to a domains request.

type Event

type Event struct {
	Metadata CFMetadata `json:"metadata"`
	Entity   struct {
		Type      string `json:"type"`
		ActorName string `json:"actor_name"`
	} `json:"entity"`
}

Event is a service instance event.

type EventsResponse

type EventsResponse struct {
	Resources []Event `json:"resources"`
	ServerResponsePagination
	ServerResponseError
}

EventsResponse is a response from the server to an events call.

type Invitation

type Invitation struct {
	Metadata CFMetadata `json:"metadata"`
	Entity   struct {
		Invitee          string   `json:"invitee"`
		Roles            []string `json:"roles"`
		AccountID        string   `json:"account_id"`
		AccountName      string   `json:"account_name"`
		OrganizationID   string   `json:"organization_id"`
		OrganizationName string   `json:"organization_name"`
		SpaceID          string   `json:"space_id"`
		SpaceName        string   `json:"space_name"`
		Status           string   `json:"status"`
	} `json:"entity"`
}

Invitation is an invitation a user received to join a specific entity.

type InvitationResponse

type InvitationResponse struct {
	Invitation
	ServerResponseError
}

InvitationResponse is a response from the server to an invitation request.

type InvitationsResponse

type InvitationsResponse struct {
	Resources []Invitation `json:"resources"`
	ServerResponsePagination
	ServerResponseError
}

InvitationsResponse is a response from the server containing invitations.

type InviteBillingAccountUserRequest

type InviteBillingAccountUserRequest struct {
	Invitee   string   `json:"invitee"`
	AccountID string   `json:"account_id"`
	Roles     []string `json:"roles"`
}

InviteBillingAccountUserRequest is the request to invite a user to a billing account.

type InviteOrgUserRequest

type InviteOrgUserRequest struct {
	Invitee string   `json:"invitee"`
	OrgID   string   `json:"organization_id"`
	Roles   []string `json:"roles"`
}

InviteOrgUserRequest is a request to invite a user to an org.

type InviteSpaceUserRequest

type InviteSpaceUserRequest struct {
	Invitee string   `json:"invitee"`
	SpaceID string   `json:"space_id"`
	Roles   []string `json:"roles"`
}

InviteSpaceUserRequest is a request to invite a user to a space.

type Plugin

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

Plugin is the Swisscom Application Cloud cf CLI plugin.

func (*Plugin) AcceptInvitation

func (p *Plugin) AcceptInvitation(c plugin.CliConnection, invitationGUID string) error

AcceptInvitation accepts a pending invitation.

func (*Plugin) Backups

func (p *Plugin) Backups(c plugin.CliConnection, serviceInstanceName string) error

Backups lists all backups for a service instance.

func (*Plugin) BillingAccountInvitations

func (p *Plugin) BillingAccountInvitations(c plugin.CliConnection, billingAccountName string) error

BillingAccountInvitations retrieves all invitations for a billing account.

func (*Plugin) CreateBackup

func (p *Plugin) CreateBackup(c plugin.CliConnection, serviceInstanceName string) error

CreateBackup creates a backup for a service instance.

func (*Plugin) CreateSSLCertificate

func (p *Plugin) CreateSSLCertificate(c plugin.CliConnection, domain string, hostname string, keyType string) error

CreateSSLCertificate creates a new SSL certificate for an FQDN.

func (*Plugin) DeclineInvitation

func (p *Plugin) DeclineInvitation(c plugin.CliConnection, invitationGUID string) error

DeclineInvitation declines a pending invitation.

func (*Plugin) DeleteBackup

func (p *Plugin) DeleteBackup(c plugin.CliConnection, serviceInstanceName string, backupGUID string) error

DeleteBackup deletes a backup of a service instance.

func (*Plugin) DisableSSL

func (p *Plugin) DisableSSL(c plugin.CliConnection, domain string, hostname string) error

DisableSSL uninstalls an existing SSL certificate.

func (*Plugin) EnableSSL

func (p *Plugin) EnableSSL(c plugin.CliConnection, domain string, hostname string) error

EnableSSL installs an existing SSL certificate.

func (*Plugin) GetMetadata

func (p *Plugin) GetMetadata() plugin.PluginMetadata

GetMetadata retrieves the metadata for the plugin.

func (*Plugin) Invitations

func (p *Plugin) Invitations(c plugin.CliConnection) error

Invitations retrieves a user's invitations.

func (*Plugin) InviteBillingAccountUser

func (p *Plugin) InviteBillingAccountUser(c plugin.CliConnection, invitee string, billingAccountName string) error

InviteBillingAccountUser invites a user to join a billing account with a specific set of roles.

func (*Plugin) InviteOrgUser

func (p *Plugin) InviteOrgUser(c plugin.CliConnection, invitee string, orgName string, roles string) error

InviteOrgUser invites a user to join an org with a specific set of roles.

func (*Plugin) InviteSpaceUser

func (p *Plugin) InviteSpaceUser(c plugin.CliConnection, invitee string, spaceName string, roles string) error

InviteSpaceUser invites a user to join an space with a specific set of roles.

func (*Plugin) OrgInvitations

func (p *Plugin) OrgInvitations(c plugin.CliConnection, orgName string) error

OrgInvitations retrieves all invitations for an org.

func (*Plugin) ResendBillingAccountInvitation

func (p *Plugin) ResendBillingAccountInvitation(c plugin.CliConnection, invitee string, billingAccountName string) error

ResendBillingAccountInvitation resends an existing billing account invitation.

func (*Plugin) ResendOrgInvitation

func (p *Plugin) ResendOrgInvitation(c plugin.CliConnection, invitee string, orgName string) error

ResendOrgInvitation resends an existing org invitation.

func (*Plugin) ResendSpaceInvitation

func (p *Plugin) ResendSpaceInvitation(c plugin.CliConnection, invitee string, spaceName string) error

ResendSpaceInvitation resends an existing space invitation.

func (*Plugin) RestoreBackup

func (p *Plugin) RestoreBackup(c plugin.CliConnection, serviceInstanceName string, backupGUID string) error

RestoreBackup creates a backup for a service instance.

func (*Plugin) RevokeSSLCertificate

func (p *Plugin) RevokeSSLCertificate(c plugin.CliConnection, domain string, hostname string) error

RevokeSSLCertificate revokes an existing SSL certificate.

func (*Plugin) Run

func (p *Plugin) Run(cliConnection plugin.CliConnection, args []string)

Run initiates the plugin.

func (*Plugin) SSLCertificates

func (p *Plugin) SSLCertificates(c plugin.CliConnection) error

SSLCertificates Lists available SSL certificates

func (*Plugin) SSLEnabled

func (p *Plugin) SSLEnabled(c plugin.CliConnection, domain string, hostname string) error

SSLEnabled tells the user whether SSL is enabled for a full domain name.

func (*Plugin) ServiceEvents

func (p *Plugin) ServiceEvents(c plugin.CliConnection, serviceInstanceName string) error

ServiceEvents retrieves events for a service instance.

func (*Plugin) SpaceInvitations

func (p *Plugin) SpaceInvitations(c plugin.CliConnection, spaceName string) error

SpaceInvitations retrieves all invitations for a space.

func (*Plugin) Tree

func (p *Plugin) Tree(c plugin.CliConnection, depth int) error

Tree renders the org tree for the current user.

type Restore

type Restore struct {
	Metadata CFMetadata `json:"metadata"`
	Entity   struct {
		Status string `json:"status"`
	} `json:"entity"`
}

Restore is a service instance restore

type RestoreBackupResponse

type RestoreBackupResponse struct {
	Restore
	ServerResponseError
}

RestoreBackupResponse is a response from the server to a restore backup call.

type SSLCertificate

type SSLCertificate struct {
	Metadata CFMetadata `json:"metadata"`
	Entity   struct {
		FullDomainName string `json:"full_domain_name"`
		Status         string `json:"status"`
	} `json:"entity"`
}

SSLCertificate is an SSL certificate which can be used to secure routes.

type SSLCertificateRequest

type SSLCertificateRequest struct {
	SpaceID        string `json:"space_id"`
	FullDomainName string `json:"full_domain_name"`
	KeyType        string `json:"key_type,omitempty"`
}

SSLCertificateRequest is the request to create an SSL certificate.

type SSLCertificateResponse

type SSLCertificateResponse struct {
	SSLCertificate
	ServerResponseError
}

SSLCertificateResponse is the response from the server from a create certificate call

type SSLCertificatesResponse

type SSLCertificatesResponse struct {
	Resources []SSLCertificate `json:"resources"`
	ServerResponsePagination
	ServerResponseError
}

SSLCertificatesResponse is a response from the server .

type ServerResponseError

type ServerResponseError struct {
	Code        int    `json:"code"`
	Description string `json:"description"`
	ErrorCode   string `json:"error_code"`
}

ServerResponseError is the response from a server which may contain an error.

type ServerResponsePagination

type ServerResponsePagination struct {
	TotalResult int    `json:"total_results"`
	TotalPages  int    `json:"total_pages"`
	PrevURL     string `json:"prev_url"`
	NextURL     string `json:"next_url"`
}

ServerResponsePagination is a server response including pagination information.

type TreeApp

type TreeApp struct {
	ID            string `json:"id"`
	Name          string `json:"name"`
	BackupIconURL string `json:"buildpack_icon_url"`
}

TreeApp is an app node of the tree structure.

type TreeOrg

type TreeOrg struct {
	ID     string      `json:"id"`
	Name   string      `json:"name"`
	Status string      `json:"status"`
	Spaces []TreeSpace `json:"spaces"`
}

TreeOrg is an org node of the tree structure.

type TreeResponse

type TreeResponse struct {
	Resources []TreeOrg `json:"resources"`
	ServerResponsePagination
	ServerResponseError
}

TreeResponse is the response of a server to a tree request.

type TreeService

type TreeService struct {
	ID             string `json:"id"`
	Name           string `json:"name"`
	ServiceIconURL string `json:"service_icon_url"`
}

TreeService is a service instance node of the tree structure.

type TreeSpace

type TreeSpace struct {
	ID               string        `json:"id"`
	Name             string        `json:"name"`
	Applications     []TreeApp     `json:"applications"`
	ServiceInstances []TreeService `json:"service_instances"`
}

TreeSpace is a space node of the tree structure.

Jump to

Keyboard shortcuts

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