Documentation
¶
Index ¶
- Constants
- type Client
- func (c *Client) ActivateSite(req ops.ActivateSiteRequest) error
- func (c *Client) CheckSiteStatus(ctx context.Context, key ops.SiteKey) error
- func (c *Client) CompleteFinalInstallStep(req ops.CompleteFinalInstallStepRequest) error
- func (c *Client) ConfigureNode(req ops.ConfigureNodeRequest) error
- func (c *Client) ConfigurePackages(req ops.ConfigurePackagesRequest) error
- func (c *Client) CreateAPIKey(ctx context.Context, req ops.NewAPIKeyRequest) (*storage.APIKey, error)
- func (c *Client) CreateAccount(req ops.NewAccountRequest) (*ops.Account, error)
- func (c *Client) CreateClusterGarbageCollectOperation(ctx context.Context, req ops.CreateClusterGarbageCollectOperationRequest) (*ops.SiteOperationKey, error)
- func (c *Client) CreateClusterReconfigureOperation(ctx context.Context, req ops.CreateClusterReconfigureOperationRequest) (*ops.SiteOperationKey, error)
- func (c *Client) CreateInstallToken(req ops.NewInstallTokenRequest) (*storage.InstallToken, error)
- func (c *Client) CreateLogEntry(key ops.SiteOperationKey, entry ops.LogEntry) error
- func (c *Client) CreateLogForwarder(ctx context.Context, key ops.SiteKey, forwarder storage.LogForwarder) error
- func (c *Client) CreateOperationPlan(key ops.SiteOperationKey, plan storage.OperationPlan) error
- func (c *Client) CreateOperationPlanChange(key ops.SiteOperationKey, change storage.PlanChange) error
- func (c *Client) CreatePackage(loc loc.Locator, data io.Reader) (*pack.PackageEnvelope, error)
- func (c *Client) CreateProgressEntry(key ops.SiteOperationKey, entry ops.ProgressEntry) error
- func (c *Client) CreateProvisioningToken(token storage.ProvisioningToken) error
- func (c *Client) CreateSite(req ops.NewSiteRequest) (*ops.Site, error)
- func (c *Client) CreateSiteAppUpdateOperation(ctx context.Context, req ops.CreateSiteAppUpdateOperationRequest) (*ops.SiteOperationKey, error)
- func (c *Client) CreateSiteExpandOperation(ctx context.Context, req ops.CreateSiteExpandOperationRequest) (*ops.SiteOperationKey, error)
- func (c *Client) CreateSiteInstallOperation(ctx context.Context, req ops.CreateSiteInstallOperationRequest) (*ops.SiteOperationKey, error)
- func (c *Client) CreateSiteShrinkOperation(ctx context.Context, req ops.CreateSiteShrinkOperationRequest) (*ops.SiteOperationKey, error)
- func (c *Client) CreateSiteUninstallOperation(ctx context.Context, req ops.CreateSiteUninstallOperationRequest) (*ops.SiteOperationKey, error)
- func (c *Client) CreateUpdateConfigOperation(ctx context.Context, req ops.CreateUpdateConfigOperationRequest) (*ops.SiteOperationKey, error)
- func (c *Client) CreateUpdateEnvarsOperation(ctx context.Context, req ops.CreateUpdateEnvarsOperationRequest) (*ops.SiteOperationKey, error)
- func (c *Client) CreateUser(req ops.NewUserRequest) error
- func (c *Client) CreateUserInvite(ctx context.Context, req ops.CreateUserInviteRequest) (*storage.UserToken, error)
- func (c *Client) CreateUserReset(ctx context.Context, req ops.CreateUserResetRequest) (*storage.UserToken, error)
- func (c *Client) DeactivateSite(req ops.DeactivateSiteRequest) error
- func (c *Client) Delete(endpoint string) (*roundtrip.Response, error)
- func (c *Client) DeleteAPIKey(ctx context.Context, userEmail, token string) error
- func (c *Client) DeleteAlert(ctx context.Context, key ops.SiteKey, name string) error
- func (c *Client) DeleteAlertTarget(ctx context.Context, key ops.SiteKey) error
- func (c *Client) DeleteClusterCertificate(ctx context.Context, key ops.SiteKey) error
- func (c *Client) DeleteGithubConnector(ctx context.Context, key ops.SiteKey, name string) error
- func (c *Client) DeleteLocalUser(name string) error
- func (c *Client) DeleteLogForwarder(ctx context.Context, key ops.SiteKey, forwarderName string) error
- func (c *Client) DeletePackage(locator loc.Locator) error
- func (c *Client) DeleteRepository(repository string) error
- func (c *Client) DeleteSMTPConfig(ctx context.Context, key ops.SiteKey) error
- func (c *Client) DeleteSite(siteKey ops.SiteKey) error
- func (c *Client) DeleteSiteOperation(key ops.SiteOperationKey) error
- func (c *Client) DeleteUser(ctx context.Context, key ops.SiteKey, name string) error
- func (c *Client) DeleteUserInvite(ctx context.Context, req ops.DeleteUserInviteRequest) error
- func (c *Client) DeleteWithParams(endpoint string, params url.Values) (*roundtrip.Response, error)
- func (c *Client) EmitAuditEvent(ctx context.Context, req ops.AuditEventRequest) error
- func (c *Client) Get(ctx context.Context, endpoint string, params url.Values) (*roundtrip.Response, error)
- func (c *Client) GetAPIKeys(userEmail string) ([]storage.APIKey, error)
- func (c *Client) GetAccount(accountID string) (*ops.Account, error)
- func (c *Client) GetAccounts() ([]ops.Account, error)
- func (c *Client) GetAlertTargets(key ops.SiteKey) ([]storage.AlertTarget, error)
- func (c *Client) GetAlerts(key ops.SiteKey) ([]storage.Alert, error)
- func (c *Client) GetAppInstaller(req ops.AppInstallerRequest) (io.ReadCloser, error)
- func (c *Client) GetApplicationEndpoints(key ops.SiteKey) ([]ops.Endpoint, error)
- func (c *Client) GetAuthGateway(key ops.SiteKey) (storage.AuthGateway, error)
- func (c *Client) GetClusterAgent(req ops.ClusterAgentRequest) (*storage.LoginEntry, error)
- func (c *Client) GetClusterAuthPreference(key ops.SiteKey) (teleservices.AuthPreference, error)
- func (c *Client) GetClusterCertificate(key ops.SiteKey, withSecrets bool) (*ops.ClusterCertificate, error)
- func (c *Client) GetClusterConfiguration(key ops.SiteKey) (clusterconfig.Interface, error)
- func (c *Client) GetClusterEnvironmentVariables(key ops.SiteKey) (storage.EnvironmentVariables, error)
- func (c *Client) GetClusterMetrics(ctx context.Context, req ops.ClusterMetricsRequest) (*ops.ClusterMetricsResponse, error)
- func (c *Client) GetClusterNodes(key ops.SiteKey) ([]ops.Node, error)
- func (c *Client) GetCurrentUser() (storage.User, error)
- func (c *Client) GetCurrentUserInfo() (*ops.UserInfo, error)
- func (c *Client) GetExpandToken(key ops.SiteKey) (*storage.ProvisioningToken, error)
- func (c *Client) GetFile(ctx context.Context, endpoint string, params url.Values) (*roundtrip.FileResponse, error)
- func (c *Client) GetGithubConnector(key ops.SiteKey, name string, withSecrets bool) (teleservices.GithubConnector, error)
- func (c *Client) GetGithubConnectors(key ops.SiteKey, withSecrets bool) ([]teleservices.GithubConnector, error)
- func (c *Client) GetLocalSite(ctx context.Context) (*ops.Site, error)
- func (c *Client) GetLocalUser(key ops.SiteKey) (storage.User, error)
- func (c *Client) GetLogForwarders(key ops.SiteKey) ([]storage.LogForwarder, error)
- func (c *Client) GetOperationPlan(key ops.SiteOperationKey) (*storage.OperationPlan, error)
- func (c *Client) GetPackages(repository string, prev *pack.PackageEnvelope, limit int) ([]pack.PackageEnvelope, error)
- func (c *Client) GetPersistentStorage(ctx context.Context, key ops.SiteKey) (storage.PersistentStorage, error)
- func (c *Client) GetRepositories(prev string, limit int) ([]string, error)
- func (c *Client) GetSMTPConfig(key ops.SiteKey) (storage.SMTPConfig, error)
- func (c *Client) GetSite(siteKey ops.SiteKey) (*ops.Site, error)
- func (c *Client) GetSiteByDomain(domainName string) (*ops.Site, error)
- func (c *Client) GetSiteExpandOperationAgentReport(ctx context.Context, key ops.SiteOperationKey) (*ops.AgentReport, error)
- func (c *Client) GetSiteInstallOperationAgentReport(ctx context.Context, key ops.SiteOperationKey) (*ops.AgentReport, error)
- func (c *Client) GetSiteInstructions(tokenID string, serverProfile string, params url.Values) (string, error)
- func (c *Client) GetSiteOperation(key ops.SiteOperationKey) (*ops.SiteOperation, error)
- func (c *Client) GetSiteOperationCrashReport(key ops.SiteOperationKey) (io.ReadCloser, error)
- func (c *Client) GetSiteOperationLogs(key ops.SiteOperationKey) (io.ReadCloser, error)
- func (c *Client) GetSiteOperationProgress(key ops.SiteOperationKey) (*ops.ProgressEntry, error)
- func (c *Client) GetSiteOperations(siteKey ops.SiteKey, f ops.OperationsFilter) (ops.SiteOperations, error)
- func (c *Client) GetSiteReport(ctx context.Context, req ops.GetClusterReportRequest) (io.ReadCloser, error)
- func (c *Client) GetSites(accountID string) ([]ops.Site, error)
- func (c *Client) GetTrustedClusterToken(key ops.SiteKey) (storage.Token, error)
- func (c *Client) GetUser(key ops.SiteKey, name string) (teleservices.User, error)
- func (c *Client) GetUserInvites(ctx context.Context, key ops.SiteKey) ([]storage.UserInvite, error)
- func (c *Client) GetUsers(key ops.SiteKey) ([]teleservices.User, error)
- func (c *Client) GetVersion(ctx context.Context) (*proto.Version, error)
- func (c *Client) GetWithContext(ctx context.Context, endpoint string, params url.Values) (*roundtrip.Response, error)
- func (c *Client) ListReleases(req ops.ListReleasesRequest) ([]storage.Release, error)
- func (c *Client) LocalClusterKey(ctx context.Context) (ops.SiteKey, error)
- func (c *Client) Ping(ctx context.Context) error
- func (c *Client) PostJSON(endpoint string, data interface{}) (*roundtrip.Response, error)
- func (c *Client) PostJSONWithContext(ctx context.Context, endpoint string, data interface{}) (*roundtrip.Response, error)
- func (c *Client) PostStream(endpoint string, reader io.Reader) (*roundtrip.Response, error)
- func (c *Client) PutJSON(endpoint string, data interface{}) (*roundtrip.Response, error)
- func (c *Client) PutJSONWithContext(ctx context.Context, endpoint string, data interface{}) (*roundtrip.Response, error)
- func (c *Client) ReadPackage(loc loc.Locator) (*pack.PackageEnvelope, io.ReadCloser, error)
- func (c *Client) ReadPackageEnvelope(loc loc.Locator) (*pack.PackageEnvelope, error)
- func (c *Client) ResetUserPassword(req ops.ResetUserPasswordRequest) (string, error)
- func (c *Client) ResumeShrink(key ops.SiteKey) (*ops.SiteOperationKey, error)
- func (c *Client) RotatePlanetConfig(req ops.RotatePlanetConfigRequest) (*ops.RotatePackageResponse, error)
- func (c *Client) RotateSecrets(req ops.RotateSecretsRequest) (*ops.RotatePackageResponse, error)
- func (c *Client) RotateTeleportConfig(req ops.RotateTeleportConfigRequest) (*ops.RotatePackageResponse, *ops.RotatePackageResponse, error)
- func (c *Client) SetOperationState(ctx context.Context, key ops.SiteOperationKey, ...) error
- func (c *Client) SignSSHKey(req ops.SSHSignRequest) (*ops.SSHSignResponse, error)
- func (c *Client) SignTLSKey(req ops.TLSSignRequest) (*ops.TLSSignResponse, error)
- func (c *Client) SiteExpandOperationStart(key ops.SiteOperationKey) error
- func (c *Client) SiteInstallOperationStart(req ops.SiteOperationKey) error
- func (c *Client) SiteUninstallOperationStart(req ops.SiteOperationKey) error
- func (c *Client) StepDown(key ops.SiteKey) error
- func (c *Client) StreamOperationLogs(key ops.SiteOperationKey, reader io.Reader) error
- func (c *Client) UpdateAlert(ctx context.Context, key ops.SiteKey, alert storage.Alert) error
- func (c *Client) UpdateAlertTarget(ctx context.Context, key ops.SiteKey, target storage.AlertTarget) error
- func (c *Client) UpdateClusterCertificate(ctx context.Context, req ops.UpdateCertificateRequest) (*ops.ClusterCertificate, error)
- func (c *Client) UpdateClusterConfiguration(req ops.UpdateClusterConfigRequest) error
- func (c *Client) UpdateClusterEnvironmentVariables(req ops.UpdateClusterEnvironRequest) error
- func (c *Client) UpdateExpandOperationState(key ops.SiteOperationKey, req ops.OperationUpdateRequest) error
- func (c *Client) UpdateInstallOperationState(key ops.SiteOperationKey, req ops.OperationUpdateRequest) error
- func (c *Client) UpdateLogForwarder(ctx context.Context, key ops.SiteKey, forwarder storage.LogForwarder) error
- func (c *Client) UpdateLogForwarders(key ops.SiteKey, forwarders []storage.LogForwarderV1) error
- func (c *Client) UpdatePersistentStorage(ctx context.Context, req ops.UpdatePersistentStorageRequest) error
- func (c *Client) UpdateSMTPConfig(ctx context.Context, key ops.SiteKey, config storage.SMTPConfig) error
- func (c *Client) UpdateUser(ctx context.Context, req ops.UpdateUserRequest) error
- func (c *Client) UpsertAuthGateway(ctx context.Context, key ops.SiteKey, gw storage.AuthGateway) error
- func (c *Client) UpsertClusterAuthPreference(ctx context.Context, key ops.SiteKey, ...) error
- func (c *Client) UpsertGithubConnector(ctx context.Context, key ops.SiteKey, connector teleservices.GithubConnector) error
- func (c *Client) UpsertRepository(repository string) error
- func (c *Client) UpsertUser(ctx context.Context, key ops.SiteKey, user teleservices.User) error
- func (c *Client) ValidateDomainName(domainName string) error
- func (c *Client) ValidateRemoteAccess(req ops.ValidateRemoteAccessRequest) (*ops.ValidateRemoteAccessResponse, error)
- func (c *Client) ValidateServers(ctx context.Context, req ops.ValidateServersRequest) (*ops.ValidateServersResponse, error)
- type ClientParam
- type UpsertResourceRawReq
Constants ¶
const CurrentVersion = "portal/v1"
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
func NewAuthenticatedClient ¶
func NewAuthenticatedClient(addr, username, password string, params ...ClientParam) (*Client, error)
NewAuthenticatedClient returns client authenticated as username with the given password
func NewBearerClient ¶
func NewBearerClient(addr, password string, params ...ClientParam) (*Client, error)
NewBearerClient returns client authenticated with the given password
func NewClient ¶
func NewClient(addr string, params ...ClientParam) (*Client, error)
NewClient returns a new Client for the specified target address addr
func (*Client) ActivateSite ¶
func (c *Client) ActivateSite(req ops.ActivateSiteRequest) error
ActivateSite moves site to the active state and, if requested, starts an application.
func (*Client) CheckSiteStatus ¶
CheckSiteStatus runs app status hook and updates site status appropriately.
func (*Client) CompleteFinalInstallStep ¶
func (c *Client) CompleteFinalInstallStep(req ops.CompleteFinalInstallStepRequest) error
CompleteFinalInstallStep marks the site as having completed the mandatory last installation step
func (*Client) ConfigureNode ¶
func (c *Client) ConfigureNode(req ops.ConfigureNodeRequest) error
ConfigureNode prepares the node for the upgrade
func (*Client) ConfigurePackages ¶
func (c *Client) ConfigurePackages(req ops.ConfigurePackagesRequest) error
ConfigurePackages packages configures packages for the specified install operation
func (*Client) CreateAPIKey ¶
func (*Client) CreateAccount ¶
func (*Client) CreateClusterGarbageCollectOperation ¶
func (c *Client) CreateClusterGarbageCollectOperation(ctx context.Context, req ops.CreateClusterGarbageCollectOperationRequest) (*ops.SiteOperationKey, error)
CreateClusterGarbageCollectOperation creates a new garbage collection operation in the cluster
func (*Client) CreateClusterReconfigureOperation ¶
func (c *Client) CreateClusterReconfigureOperation(ctx context.Context, req ops.CreateClusterReconfigureOperationRequest) (*ops.SiteOperationKey, error)
CreateClusterReconfigureOperation creates a new cluster reconfiguration operation.
func (*Client) CreateInstallToken ¶
func (c *Client) CreateInstallToken(req ops.NewInstallTokenRequest) (*storage.InstallToken, error)
func (*Client) CreateLogEntry ¶
func (*Client) CreateLogForwarder ¶
func (c *Client) CreateLogForwarder(ctx context.Context, key ops.SiteKey, forwarder storage.LogForwarder) error
CreateLogForwarder creates a new log forwarder
func (*Client) CreateOperationPlan ¶
func (c *Client) CreateOperationPlan(key ops.SiteOperationKey, plan storage.OperationPlan) error
CreateOperationPlan saves the provided operation plan
func (*Client) CreateOperationPlanChange ¶
func (c *Client) CreateOperationPlanChange(key ops.SiteOperationKey, change storage.PlanChange) error
CreateOperationPlanChange creates a new changelog entry for a plan
func (*Client) CreatePackage ¶
func (*Client) CreateProgressEntry ¶
func (c *Client) CreateProgressEntry(key ops.SiteOperationKey, entry ops.ProgressEntry) error
func (*Client) CreateProvisioningToken ¶
func (c *Client) CreateProvisioningToken(token storage.ProvisioningToken) error
func (*Client) CreateSite ¶
func (*Client) CreateSiteAppUpdateOperation ¶
func (c *Client) CreateSiteAppUpdateOperation(ctx context.Context, req ops.CreateSiteAppUpdateOperationRequest) (*ops.SiteOperationKey, error)
func (*Client) CreateSiteExpandOperation ¶
func (c *Client) CreateSiteExpandOperation(ctx context.Context, req ops.CreateSiteExpandOperationRequest) (*ops.SiteOperationKey, error)
func (*Client) CreateSiteInstallOperation ¶
func (c *Client) CreateSiteInstallOperation(ctx context.Context, req ops.CreateSiteInstallOperationRequest) (*ops.SiteOperationKey, error)
func (*Client) CreateSiteShrinkOperation ¶
func (c *Client) CreateSiteShrinkOperation(ctx context.Context, req ops.CreateSiteShrinkOperationRequest) (*ops.SiteOperationKey, error)
func (*Client) CreateSiteUninstallOperation ¶
func (c *Client) CreateSiteUninstallOperation(ctx context.Context, req ops.CreateSiteUninstallOperationRequest) (*ops.SiteOperationKey, error)
func (*Client) CreateUpdateConfigOperation ¶
func (c *Client) CreateUpdateConfigOperation(ctx context.Context, req ops.CreateUpdateConfigOperationRequest) (*ops.SiteOperationKey, error)
CreateUpdateConfigOperation creates a new operation to update cluster configuration
func (*Client) CreateUpdateEnvarsOperation ¶
func (c *Client) CreateUpdateEnvarsOperation(ctx context.Context, req ops.CreateUpdateEnvarsOperationRequest) (*ops.SiteOperationKey, error)
CreateUpdateEnvarsOperation creates a new operation to update cluster runtime environment variables
func (*Client) CreateUser ¶
func (c *Client) CreateUser(req ops.NewUserRequest) error
func (*Client) CreateUserInvite ¶
func (c *Client) CreateUserInvite(ctx context.Context, req ops.CreateUserInviteRequest) (*storage.UserToken, error)
CreateUserInvite creates a new invite token for a user.
func (*Client) CreateUserReset ¶
func (c *Client) CreateUserReset(ctx context.Context, req ops.CreateUserResetRequest) (*storage.UserToken, error)
CreateUserReset creates a new reset token for a user.
func (*Client) DeactivateSite ¶
func (c *Client) DeactivateSite(req ops.DeactivateSiteRequest) error
DeactivateSite puts the site in the degraded state and, if requested, stops an application.
func (*Client) DeleteAPIKey ¶
func (*Client) DeleteAlert ¶
DeleteAlert deletes a cluster monitoring alert specified with name
func (*Client) DeleteAlertTarget ¶
DeleteAlertTarget deletes the cluster monitoring alert target
func (*Client) DeleteClusterCertificate ¶
DeleteClusterCertificate deletes the cluster certificate
func (*Client) DeleteGithubConnector ¶
DeleteGithubConnector deletes a Github connector by name
func (*Client) DeleteLocalUser ¶
func (*Client) DeleteLogForwarder ¶
func (c *Client) DeleteLogForwarder(ctx context.Context, key ops.SiteKey, forwarderName string) error
DeleteLogForwarder deletes a log forwarder
func (*Client) DeleteRepository ¶
func (*Client) DeleteSMTPConfig ¶
DeleteSMTPConfig deletes the cluster SMTP configuration
func (*Client) DeleteSiteOperation ¶
func (c *Client) DeleteSiteOperation(key ops.SiteOperationKey) error
func (*Client) DeleteUser ¶
DeleteUser deletes user by name
func (*Client) DeleteUserInvite ¶
DeleteUserInvite deletes the specified user invite.
func (*Client) DeleteWithParams ¶
DeleteWithParams issues HTTP DELETE request to the server
func (*Client) EmitAuditEvent ¶
EmitAuditEvent saves the provided event in the audit log.
func (*Client) Get ¶
func (c *Client) Get(ctx context.Context, endpoint string, params url.Values) (*roundtrip.Response, error)
Get issues HTTP GET request to the server
func (*Client) GetAlertTargets ¶
GetAlertTargets returns a list of monitoring alert targets for the cluster
func (*Client) GetAppInstaller ¶
func (c *Client) GetAppInstaller(req ops.AppInstallerRequest) (io.ReadCloser, error)
func (*Client) GetApplicationEndpoints ¶
func (*Client) GetAuthGateway ¶
GetAuthGateway returns auth gateway configuration.
func (*Client) GetClusterAgent ¶
func (c *Client) GetClusterAgent(req ops.ClusterAgentRequest) (*storage.LoginEntry, error)
func (*Client) GetClusterAuthPreference ¶
func (c *Client) GetClusterAuthPreference(key ops.SiteKey) (teleservices.AuthPreference, error)
GetClusterAuthPreference returns cluster auth preference
func (*Client) GetClusterCertificate ¶
func (c *Client) GetClusterCertificate(key ops.SiteKey, withSecrets bool) (*ops.ClusterCertificate, error)
GetClusterCertificate returns the cluster certificate
func (*Client) GetClusterConfiguration ¶
GetClusterConfiguration retrieves the cluster configuration
func (*Client) GetClusterEnvironmentVariables ¶
func (c *Client) GetClusterEnvironmentVariables(key ops.SiteKey) (storage.EnvironmentVariables, error)
GetClusterEnvironmentVariables retrieves the cluster runtime environment variables
func (*Client) GetClusterMetrics ¶
func (c *Client) GetClusterMetrics(ctx context.Context, req ops.ClusterMetricsRequest) (*ops.ClusterMetricsResponse, error)
GetClusterMetrics returns basic CPU/RAM metrics for the specified cluster.
func (*Client) GetClusterNodes ¶
GetClusterNodes returns a real-time information about cluster nodes
func (*Client) GetCurrentUser ¶
GetCurrentUser returns user that is currently logged in
func (*Client) GetCurrentUserInfo ¶
GetCurrentUserInfo returns user that is currently logged in
func (*Client) GetExpandToken ¶
func (*Client) GetFile ¶
func (c *Client) GetFile(ctx context.Context, endpoint string, params url.Values) (*roundtrip.FileResponse, error)
GetFile issues HTTP GET request to the server to download a file
func (*Client) GetGithubConnector ¶
func (c *Client) GetGithubConnector(key ops.SiteKey, name string, withSecrets bool) (teleservices.GithubConnector, error)
GetGithubConnector returns a Github connector by name
Returned connector exclude client secret unless withSecrets is true.
func (*Client) GetGithubConnectors ¶
func (c *Client) GetGithubConnectors(key ops.SiteKey, withSecrets bool) ([]teleservices.GithubConnector, error)
GetGithubConnectors returns all Github connectors
Returned connectors exclude client secret unless withSecrets is true.
func (*Client) GetLogForwarders ¶
GetLogForwarders returns a list of configured log forwarders
func (*Client) GetOperationPlan ¶
func (c *Client) GetOperationPlan(key ops.SiteOperationKey) (*storage.OperationPlan, error)
GetOperationPlan returns plan for the specified operation
func (*Client) GetPackages ¶
func (c *Client) GetPackages(repository string, prev *pack.PackageEnvelope, limit int) ([]pack.PackageEnvelope, error)
func (*Client) GetPersistentStorage ¶
func (c *Client) GetPersistentStorage(ctx context.Context, key ops.SiteKey) (storage.PersistentStorage, error)
GetPersistentStorage retrieves cluster persistent storage configuration.
func (*Client) GetRepositories ¶
func (*Client) GetSMTPConfig ¶
GetSMTPConfig returns the cluster SMTP configuration
func (*Client) GetSiteByDomain ¶
func (*Client) GetSiteExpandOperationAgentReport ¶
func (c *Client) GetSiteExpandOperationAgentReport(ctx context.Context, key ops.SiteOperationKey) (*ops.AgentReport, error)
func (*Client) GetSiteInstallOperationAgentReport ¶
func (c *Client) GetSiteInstallOperationAgentReport(ctx context.Context, key ops.SiteOperationKey) (*ops.AgentReport, error)
func (*Client) GetSiteInstructions ¶
func (c *Client) GetSiteInstructions(tokenID string, serverProfile string, params url.Values) (string, error)
GetSiteInstructions returns shell script with instructions to execute for particular install agent params are url query parameters that are optional and can optionally specify selected interface
func (*Client) GetSiteOperation ¶
func (c *Client) GetSiteOperation(key ops.SiteOperationKey) (*ops.SiteOperation, error)
func (*Client) GetSiteOperationCrashReport ¶
func (c *Client) GetSiteOperationCrashReport(key ops.SiteOperationKey) (io.ReadCloser, error)
func (*Client) GetSiteOperationLogs ¶
func (c *Client) GetSiteOperationLogs(key ops.SiteOperationKey) (io.ReadCloser, error)
func (*Client) GetSiteOperationProgress ¶
func (c *Client) GetSiteOperationProgress(key ops.SiteOperationKey) (*ops.ProgressEntry, error)
func (*Client) GetSiteOperations ¶
func (c *Client) GetSiteOperations(siteKey ops.SiteKey, f ops.OperationsFilter) (ops.SiteOperations, error)
GetSiteOperations returns site operations filtered by the provided filter.
func (*Client) GetSiteReport ¶
func (c *Client) GetSiteReport(ctx context.Context, req ops.GetClusterReportRequest) (io.ReadCloser, error)
func (*Client) GetTrustedClusterToken ¶
GetTrustedClusterToken returns the token for the specified trusted cluster TODO(r0mant) Move to enterprise.
func (*Client) GetUserInvites ¶
GetUserInvites returns all active user invites.
func (*Client) GetVersion ¶
GetVersion returns the server version information.
func (*Client) GetWithContext ¶
func (c *Client) GetWithContext(ctx context.Context, endpoint string, params url.Values) (*roundtrip.Response, error)
GetWithContext issues HTTP GET request to the server bound to the specified context
func (*Client) ListReleases ¶
ListReleases returns all currently installed application releases in a cluster.
func (*Client) LocalClusterKey ¶
LocalClusterKey retrieves the SiteKey for the local cluster
func (*Client) PostJSON ¶
PostJSON issues HTTP POST request to the server with the provided JSON data
func (*Client) PostJSONWithContext ¶
func (c *Client) PostJSONWithContext(ctx context.Context, endpoint string, data interface{}) (*roundtrip.Response, error)
PostJSONWithContext issues HTTP POST request to the server with the provided JSON data bounded by the specified context
func (*Client) PostStream ¶
PostStream makes a POST request to the server using data from the provided reader as request body
func (*Client) PutJSONWithContext ¶
func (c *Client) PutJSONWithContext(ctx context.Context, endpoint string, data interface{}) (*roundtrip.Response, error)
PutJSONWithContext issues HTTP PUT request bound to the given context to the server with the provided JSON data
func (*Client) ReadPackage ¶
func (c *Client) ReadPackage(loc loc.Locator) (*pack.PackageEnvelope, io.ReadCloser, error)
func (*Client) ReadPackageEnvelope ¶
func (*Client) ResetUserPassword ¶
func (c *Client) ResetUserPassword(req ops.ResetUserPasswordRequest) (string, error)
func (*Client) ResumeShrink ¶
func (*Client) RotatePlanetConfig ¶
func (c *Client) RotatePlanetConfig(req ops.RotatePlanetConfigRequest) (*ops.RotatePackageResponse, error)
RotatePlanetConfig rotates planet configuration package for the server specified in the request
func (*Client) RotateSecrets ¶
func (c *Client) RotateSecrets(req ops.RotateSecretsRequest) (*ops.RotatePackageResponse, error)
RotateSecrets rotates secrets package for the server specified in the request
func (*Client) RotateTeleportConfig ¶
func (c *Client) RotateTeleportConfig(req ops.RotateTeleportConfigRequest) (*ops.RotatePackageResponse, *ops.RotatePackageResponse, error)
RotateTeleportConfig rotates teleport configuration package for the server specified in the request
func (*Client) SetOperationState ¶
func (c *Client) SetOperationState(ctx context.Context, key ops.SiteOperationKey, req ops.SetOperationStateRequest) error
SetOperationState moves operation into specified state
func (*Client) SignSSHKey ¶
func (c *Client) SignSSHKey(req ops.SSHSignRequest) (*ops.SSHSignResponse, error)
SignSSHKey signs SSH Public Key with SSH user certificate authority of this site
func (*Client) SignTLSKey ¶
func (c *Client) SignTLSKey(req ops.TLSSignRequest) (*ops.TLSSignResponse, error)
SignTLSKey signs X509 Public Key with X509 certificate authority of this site
func (*Client) SiteExpandOperationStart ¶
func (c *Client) SiteExpandOperationStart(key ops.SiteOperationKey) error
func (*Client) SiteInstallOperationStart ¶
func (c *Client) SiteInstallOperationStart(req ops.SiteOperationKey) error
func (*Client) SiteUninstallOperationStart ¶
func (c *Client) SiteUninstallOperationStart(req ops.SiteOperationKey) error
func (*Client) StepDown ¶
StepDown asks the process to pause its leader election heartbeat so it can give up its leadership
func (*Client) StreamOperationLogs ¶
StreamOperationLogs appends the logs from the provided reader to the specified operation (user-facing) log file
func (*Client) UpdateAlert ¶
UpdateAlert updates the specified monitoring alert
func (*Client) UpdateAlertTarget ¶
func (c *Client) UpdateAlertTarget(ctx context.Context, key ops.SiteKey, target storage.AlertTarget) error
UpdateAlertTarget updates the monitoring alert target
func (*Client) UpdateClusterCertificate ¶
func (c *Client) UpdateClusterCertificate(ctx context.Context, req ops.UpdateCertificateRequest) (*ops.ClusterCertificate, error)
UpdateClusterCertificate updates the cluster certificate
func (*Client) UpdateClusterConfiguration ¶
func (c *Client) UpdateClusterConfiguration(req ops.UpdateClusterConfigRequest) error
UpdateClusterConfiguration updates the cluster configuration from the specified request
func (*Client) UpdateClusterEnvironmentVariables ¶
func (c *Client) UpdateClusterEnvironmentVariables(req ops.UpdateClusterEnvironRequest) error
UpdateClusterEnvironmentVariables updates the cluster runtime environment variables from the specified request
func (*Client) UpdateExpandOperationState ¶
func (c *Client) UpdateExpandOperationState(key ops.SiteOperationKey, req ops.OperationUpdateRequest) error
UpdateExpandOperationState updates the state of an expand operation
func (*Client) UpdateInstallOperationState ¶
func (c *Client) UpdateInstallOperationState(key ops.SiteOperationKey, req ops.OperationUpdateRequest) error
UpdateInstallOperationState updates the state of an install operation
func (*Client) UpdateLogForwarder ¶
func (c *Client) UpdateLogForwarder(ctx context.Context, key ops.SiteKey, forwarder storage.LogForwarder) error
UpdateLogForwarder updates an existing log forwarder
func (*Client) UpdateLogForwarders ¶
UpdateLogForwarders replaces the list of active log forwarders TODO(r0mant,alexeyk) this is a legacy method used only by UI, alexeyk to remove it when refactoring resources and use upsert/delete instead
func (*Client) UpdatePersistentStorage ¶
func (c *Client) UpdatePersistentStorage(ctx context.Context, req ops.UpdatePersistentStorageRequest) error
UpdatePersistentStorage updates persistent storage configuration.
func (*Client) UpdateSMTPConfig ¶
func (c *Client) UpdateSMTPConfig(ctx context.Context, key ops.SiteKey, config storage.SMTPConfig) error
UpdateSMTPConfig updates the cluster SMTP configuration
func (*Client) UpdateUser ¶
UpdateUser updates the specified user information.
func (*Client) UpsertAuthGateway ¶
func (c *Client) UpsertAuthGateway(ctx context.Context, key ops.SiteKey, gw storage.AuthGateway) error
UpsertAuthGateway updates auth gateway configuration.
func (*Client) UpsertClusterAuthPreference ¶
func (c *Client) UpsertClusterAuthPreference(ctx context.Context, key ops.SiteKey, authPreference teleservices.AuthPreference) error
UpsertClusterAuthPreference updates cluster auth preference
func (*Client) UpsertGithubConnector ¶
func (c *Client) UpsertGithubConnector(ctx context.Context, key ops.SiteKey, connector teleservices.GithubConnector) error
UpsertGithubConnector creates or updates a Github connector
func (*Client) UpsertRepository ¶
func (*Client) UpsertUser ¶
UpsertUser creates or updates the user
func (*Client) ValidateDomainName ¶
func (*Client) ValidateRemoteAccess ¶
func (c *Client) ValidateRemoteAccess(req ops.ValidateRemoteAccessRequest) (*ops.ValidateRemoteAccessResponse, error)
func (*Client) ValidateServers ¶
func (c *Client) ValidateServers(ctx context.Context, req ops.ValidateServersRequest) (*ops.ValidateServersResponse, error)
ValidateServers runs pre-installation checks
type ClientParam ¶
ClientParam defines the API to override configuration on client c
func BasicAuth ¶
func BasicAuth(username, password string) ClientParam
BasicAuth sets username and password for HTTP client
func BearerAuth ¶
func BearerAuth(password string) ClientParam
BearerAuth sets token for HTTP client
func HTTPClient ¶
func HTTPClient(h *http.Client) ClientParam
HTTPClient is a functional parameter that sets the internal HTTP client
func WithLocalDialer ¶
func WithLocalDialer(dialer httplib.Dialer) ClientParam
WithLocalDialer specifies the dialer to use for connecting to an endpoint if standard dialing fails
type UpsertResourceRawReq ¶
type UpsertResourceRawReq struct { // Resource is a raw JSON data of a resource Resource json.RawMessage `json:"resource"` // TTL is the resource TTL TTL time.Duration `json:"ttl"` }
UpsertResourceRawReq is a request to upsert a resource