Documentation ¶
Index ¶
- type Router
- func (r *Router) AcceptRemoteCluster(req ops.AcceptRemoteClusterRequest) (*ops.AcceptRemoteClusterResponse, error)
- func (r *Router) CheckForUpdate(key ossops.SiteKey) (*loc.Locator, error)
- func (r *Router) CheckSiteLicense(ctx context.Context, key ossops.SiteKey) error
- func (r *Router) DeleteOIDCConnector(ctx context.Context, key ossops.SiteKey, name string) error
- func (r *Router) DeleteRole(ctx context.Context, key ossops.SiteKey, name string) error
- func (r *Router) DeleteSAMLConnector(ctx context.Context, key ossops.SiteKey, name string) error
- func (r *Router) DeleteTrustedCluster(ctx context.Context, req ops.DeleteTrustedClusterRequest) error
- func (r *Router) DisablePeriodicUpdates(ctx context.Context, key ossops.SiteKey) error
- func (r *Router) DownloadUpdate(ctx context.Context, req ops.DownloadUpdateRequest) error
- func (r *Router) EnablePeriodicUpdates(ctx context.Context, req ops.EnablePeriodicUpdatesRequest) error
- func (r *Router) GetClusterEndpoints(key ossops.SiteKey) (storage.Endpoints, error)
- func (r *Router) GetLicenseCA() ([]byte, error)
- func (r *Router) GetOIDCConnector(key ossops.SiteKey, name string, withSecrets bool) (teleservices.OIDCConnector, error)
- func (r *Router) GetOIDCConnectors(key ossops.SiteKey, withSecrets bool) ([]teleservices.OIDCConnector, error)
- func (r *Router) GetRole(key ossops.SiteKey, name string) (teleservices.Role, error)
- func (r *Router) GetRoles(key ossops.SiteKey) ([]teleservices.Role, error)
- func (r *Router) GetSAMLConnector(key ossops.SiteKey, name string, withSecrets bool) (teleservices.SAMLConnector, error)
- func (r *Router) GetSAMLConnectors(key ossops.SiteKey, withSecrets bool) ([]teleservices.SAMLConnector, error)
- func (r *Router) GetTrustedCluster(key ossops.SiteKey, name string) (storage.TrustedCluster, error)
- func (r *Router) GetTrustedClusters(key ossops.SiteKey) ([]storage.TrustedCluster, error)
- func (r *Router) NewLicense(ctx context.Context, req ops.NewLicenseRequest) (string, error)
- func (r *Router) PeriodicUpdatesStatus(key ossops.SiteKey) (*ops.PeriodicUpdatesStatusResponse, error)
- func (r *Router) RegisterAgent(req ops.RegisterAgentRequest) (*ops.RegisterAgentResponse, error)
- func (r *Router) RemoveRemoteCluster(req ops.RemoveRemoteClusterRequest) error
- func (r *Router) RequestClusterCopy(req ops.ClusterCopyRequest) error
- func (r *Router) StartPeriodicUpdates(key ossops.SiteKey) error
- func (r *Router) StopPeriodicUpdates(key ossops.SiteKey) error
- func (r *Router) UpdateClusterEndpoints(ctx context.Context, key ossops.SiteKey, endpoints storage.Endpoints) error
- func (r *Router) UpdateLicense(ctx context.Context, req ops.UpdateLicenseRequest) error
- func (r *Router) UpsertOIDCConnector(ctx context.Context, key ossops.SiteKey, connector teleservices.OIDCConnector) error
- func (r *Router) UpsertRole(ctx context.Context, key ossops.SiteKey, role teleservices.Role) error
- func (r *Router) UpsertSAMLConnector(ctx context.Context, key ossops.SiteKey, connector teleservices.SAMLConnector) error
- func (r *Router) UpsertTrustedCluster(ctx context.Context, key ossops.SiteKey, cluster storage.TrustedCluster) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Router ¶
type Router struct { // Router is the wrapped open-source router *ossrouter.Router // Local is the local cluster operator service Local *service.Operator }
Router extends the open-source operator router
func (*Router) AcceptRemoteCluster ¶
func (r *Router) AcceptRemoteCluster(req ops.AcceptRemoteClusterRequest) (*ops.AcceptRemoteClusterResponse, error)
AcceptRemoteCluster defines the handshake between a remote cluster and this Ops Center
func (*Router) CheckForUpdate ¶
CheckForUpdate checks with remote OpsCenter if there is a newer version of the installed application
func (*Router) CheckSiteLicense ¶
CheckSiteLicense makes sure the license installed on cluster is correct
func (*Router) DeleteOIDCConnector ¶
DeleteOIDCConnector deletes an OIDC connector by name
func (*Router) DeleteRole ¶
DeleteRole deletes a role by name
func (*Router) DeleteSAMLConnector ¶
DeleteSAMLConnector deletes a SAML connector by name
func (*Router) DeleteTrustedCluster ¶
func (r *Router) DeleteTrustedCluster(ctx context.Context, req ops.DeleteTrustedClusterRequest) error
DeleteTrustedCluster deletes a trusted cluster by name
func (*Router) DisablePeriodicUpdates ¶
DisablePeriodicUpdates turns periodic updates for the cluster off and stops the update fetch loop if it's running
func (*Router) DownloadUpdate ¶
DownloadUpdate downloads the provided application version from remote Ops Center
func (*Router) EnablePeriodicUpdates ¶
func (r *Router) EnablePeriodicUpdates(ctx context.Context, req ops.EnablePeriodicUpdatesRequest) error
EnablePeriodicUpdates turns periodic updates for the cluster on or updates the interval
func (*Router) GetClusterEndpoints ¶
GetClusterEndpoints returns the cluster management endpoints such as control panel advertise address and agents advertise address
func (*Router) GetLicenseCA ¶
GetLicenseCA returns CA certificate Ops Center uses to sign licenses
func (*Router) GetOIDCConnector ¶
func (r *Router) GetOIDCConnector(key ossops.SiteKey, name string, withSecrets bool) (teleservices.OIDCConnector, error)
GetOIDCConnector returns an OIDC connector by name
Returned connector exclude client secret unless withSecrets is true.
func (*Router) GetOIDCConnectors ¶
func (r *Router) GetOIDCConnectors(key ossops.SiteKey, withSecrets bool) ([]teleservices.OIDCConnector, error)
GetOIDCConnectors returns all OIDC connectors
Returned connectors exclude client secret unless withSecrets is true.
func (*Router) GetSAMLConnector ¶
func (r *Router) GetSAMLConnector(key ossops.SiteKey, name string, withSecrets bool) (teleservices.SAMLConnector, error)
GetSAMLConnector returns a SAML connector by name
Returned connector excludes private signing key unless withSecrets is true.
func (*Router) GetSAMLConnectors ¶
func (r *Router) GetSAMLConnectors(key ossops.SiteKey, withSecrets bool) ([]teleservices.SAMLConnector, error)
GetSAMLConnectors returns all SAML connectors
Returned connectors exclude private signing keys unless withSecrets is true.
func (*Router) GetTrustedCluster ¶
GetTrustedCluster returns trusted cluster by name
func (*Router) GetTrustedClusters ¶
GetTrustedClusters returns a list of configured trusted clusters
func (*Router) NewLicense ¶
NewLicense generates a new license signed with this Ops Center CA
func (*Router) PeriodicUpdatesStatus ¶
func (r *Router) PeriodicUpdatesStatus(key ossops.SiteKey) (*ops.PeriodicUpdatesStatusResponse, error)
PeriodicUpdatesStatus returns the status of periodic updates for the cluster
func (*Router) RegisterAgent ¶
func (r *Router) RegisterAgent(req ops.RegisterAgentRequest) (*ops.RegisterAgentResponse, error)
RegisterAgent registers an install agent
func (*Router) RemoveRemoteCluster ¶
func (r *Router) RemoveRemoteCluster(req ops.RemoveRemoteClusterRequest) error
RemoveRemoteCluster removes the cluster entry specified in the request
func (*Router) RequestClusterCopy ¶
func (r *Router) RequestClusterCopy(req ops.ClusterCopyRequest) error
RequestClusterCopy replicates the cluster specified in the provided request and its data from the remote Ops Center
func (*Router) StartPeriodicUpdates ¶
StartPeriodicUpdates starts periodic updates check
func (*Router) StopPeriodicUpdates ¶
StopPeriodicUpdates stops periodic updates check without disabling it
func (*Router) UpdateClusterEndpoints ¶
func (r *Router) UpdateClusterEndpoints(ctx context.Context, key ossops.SiteKey, endpoints storage.Endpoints) error
UpdateClusterEndpoints updates the cluster management endpoints
func (*Router) UpdateLicense ¶
UpdateLicense updates license installed on cluster and runs a respective app hook
func (*Router) UpsertOIDCConnector ¶
func (r *Router) UpsertOIDCConnector(ctx context.Context, key ossops.SiteKey, connector teleservices.OIDCConnector) error
UpsertOIDCConnector creates or updates an OIDC connector
func (*Router) UpsertRole ¶
UpsertRole creates a new role
func (*Router) UpsertSAMLConnector ¶
func (r *Router) UpsertSAMLConnector(ctx context.Context, key ossops.SiteKey, connector teleservices.SAMLConnector) error
UpsertSAMLConnector creates or updates a SAML connector
func (*Router) UpsertTrustedCluster ¶
func (r *Router) UpsertTrustedCluster(ctx context.Context, key ossops.SiteKey, cluster storage.TrustedCluster) error
UpsertTrustedCluster creates or updates a trusted cluster