shared

package
v0.11.0 Latest Latest
Warning

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

Go to latest
Published: Jan 19, 2023 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ParseNamespaceID

func ParseNamespaceID(namespaceID string) (string, string, string, error)

func SetSatelliteForApplication

func SetSatelliteForApplication(application applicationv1.ApplicationSpec, satellite string) applicationv1.ApplicationSpec

func SetSatelliteForDashboard

func SetSatelliteForDashboard(dashboard dashboardv1.DashboardSpec, satellite string) dashboardv1.DashboardSpec

func SetSatelliteForTeam

func SetSatelliteForTeam(team teamv1.TeamSpec, satellite string) teamv1.TeamSpec

func SetSatelliteForUser

func SetSatelliteForUser(user userv1.UserSpec, satellite string) userv1.UserSpec

Types

type Cluster

type Cluster struct {
	ID        string `json:"id" bson:"_id"`
	Cluster   string `json:"cluster"`
	Satellite string `json:"satellite"`
	UpdatedAt int64  `json:"updatedAt"`
}

type Namespace

type Namespace struct {
	ID        string `json:"id" bson:"_id"`
	Namespace string `json:"namespace"`
	Cluster   string `json:"cluster"`
	Satellite string `json:"satellite"`
	ClusterID string `json:"clusterID" boltholdIndex:"ClusterID"`
	UpdatedAt int64  `json:"updatedAt"`
}

type Resource

type Resource struct {
	ID          string              `json:"id"`
	IsCRD       bool                `json:"isCRD"`
	Path        string              `json:"path"`
	Resource    string              `json:"resource"`
	Title       string              `json:"title"`
	Description string              `json:"description"`
	Scope       string              `json:"scope"`
	Colums      []cluster.CRDColumn `json:"columns"`
}

func CRDToResource

func CRDToResource(crd cluster.CRD) Resource

func GetResourceByID

func GetResourceByID(id string) Resource

func GetResources

func GetResources(crds []cluster.CRD) []Resource

type Tag

type Tag struct {
	ID        string `json:"id" bson:"_id"`
	Tag       string `json:"tag"`
	UpdatedAt int64  `json:"updatedAt"`
}

type Topology

type Topology struct {
	ID                  string `json:"id" bson:"_id"`
	SourceID            string `json:"sourceID"`
	SourceSatellite     string `json:"sourceSatellite"`
	SourceCluster       string `json:"sourceCluster"`
	SourceNamespace     string `json:"SourceNamespace"`
	SourceName          string `json:"SourceName"`
	TargetID            string `json:"targetID"`
	TargetSatellite     string `json:"targetSatellite"`
	TargetCluster       string `json:"targetCluster"`
	TargetNamespace     string `json:"targetNamespace"`
	TargetName          string `json:"targetName"`
	TopologyExternal    bool   `json:"topologyExternal"`
	TopologyDescription string `json:"topologyDescription"`
	UpdatedAt           int64  `json:"updatedAt"`
}

Topology is the structure of the saved topology data in our store.

Jump to

Keyboard shortcuts

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