Documentation ¶
Index ¶
- Constants
- Variables
- type Backup
- type BackupHandler
- type BackupList
- type BaseHandler
- type Cluster
- type ClusterHandler
- type ClusterList
- type ClusterScoped
- type Container
- type ContainerFilter
- type DirectImage
- type DirectImageList
- type DirectImageMigrationHandler
- func (h DirectImageMigrationHandler) AddRoutes(r *gin.Engine)
- func (h DirectImageMigrationHandler) Get(ctx *gin.Context)
- func (h DirectImageMigrationHandler) Link(m *model.DirectImageMigration) string
- func (h DirectImageMigrationHandler) List(ctx *gin.Context)
- func (h *DirectImageMigrationHandler) Prepare(ctx *gin.Context) int
- type DirectImageStream
- type DirectImageStreamList
- type DirectImageStreamMigrationHandler
- func (h DirectImageStreamMigrationHandler) AddRoutes(r *gin.Engine)
- func (h DirectImageStreamMigrationHandler) Get(ctx *gin.Context)
- func (h DirectImageStreamMigrationHandler) Link(m *model.DirectImageStreamMigration) string
- func (h DirectImageStreamMigrationHandler) List(ctx *gin.Context)
- func (h *DirectImageStreamMigrationHandler) Prepare(ctx *gin.Context) int
- type DirectVolume
- type DirectVolumeList
- type DirectVolumeMigrationHandler
- func (h DirectVolumeMigrationHandler) AddRoutes(r *gin.Engine)
- func (h DirectVolumeMigrationHandler) Get(ctx *gin.Context)
- func (h DirectVolumeMigrationHandler) Link(m *model.DirectVolumeMigration) string
- func (h DirectVolumeMigrationHandler) List(ctx *gin.Context)
- func (h *DirectVolumeMigrationHandler) Prepare(ctx *gin.Context) int
- type DirectVolumeMigrationProgressHandler
- func (h DirectVolumeMigrationProgressHandler) AddRoutes(r *gin.Engine)
- func (h DirectVolumeMigrationProgressHandler) Get(ctx *gin.Context)
- func (h DirectVolumeMigrationProgressHandler) Link(m *model.DirectVolumeMigrationProgress) string
- func (h DirectVolumeMigrationProgressHandler) List(ctx *gin.Context)
- func (h *DirectVolumeMigrationProgressHandler) Prepare(ctx *gin.Context) int
- type DirectVolumeProgress
- type DirectVolumeProgressList
- type Event
- type EventHandler
- type EventList
- type Hook
- type HookHandler
- type HookList
- type Job
- type JobHandler
- type JobList
- type LogHandler
- type MigResource
- type Migration
- type MigrationHandler
- type MigrationList
- type Namespace
- type NamespaceList
- type NsHandler
- type PV
- type PVC
- type Params
- type Plan
- type PlanHandler
- func (h PlanHandler) AddRoutes(r *gin.Engine)
- func (h PlanHandler) Get(ctx *gin.Context)
- func (h PlanHandler) Link(m *model.Plan) string
- func (h PlanHandler) List(ctx *gin.Context)
- func (h PlanHandler) Pods(ctx *gin.Context)
- func (h *PlanHandler) Prepare(ctx *gin.Context) int
- func (h PlanHandler) Tree(ctx *gin.Context)
- type PlanList
- type PlanPod
- type PlanPods
- type PlanTree
- type Pod
- type PodHandler
- type PodList
- type PvBackup
- type PvBackupHandler
- type PvBackupList
- type PvHandler
- type PvList
- type PvRestore
- type PvRestoreHandler
- type PvRestoreList
- type PvcHandler
- type PvcList
- type RequestHandler
- type Restore
- type RestoreHandler
- type RestoreList
- type RootNsHandler
- type Route
- type RouteHandler
- type RouteList
- type SchemaHandler
- type Service
- type ServiceHandler
- type ServiceList
- type StorageClass
- type StorageClassHandler
- type StorageClassList
- type TreeNode
- type VirtualMachine
- type VirtualMachineHandler
- type VirtualMachineList
- type WebServer
Constants ¶
const ( BackupParam = "backup" BackupsRoot = NamespaceRoot + "/backups" BackupRoot = BackupsRoot + "/:" + BackupParam )
Backup route root.
const ( ClusterParam = "cluster" ClustersRoot = Root + "/clusters" ClusterRoot = ClustersRoot + "/:" + ClusterParam )
Cluster-scoped route roots.
const ( DirectImageParam = "directimagemigration" DirectImagesRoot = Root + "/directimagemigrations" DirectImageRoot = DirectImagesRoot + "/:" + DirectImageParam )
const ( DirectImageStreamParam = "directimagestreammigration" DirectImageStreamsRoot = Root + "/directimagestreammigrations" DirectImageStreamRoot = DirectImageStreamsRoot + "/:" + DirectImageStreamParam )
const ( DirectVolumeParam = "directvolumemigration" DirectVolumesRoot = Root + "/directvolumemigrations" DirectVolumeRoot = DirectVolumesRoot + "/:" + DirectVolumeParam )
const ( DirectVolumeProgressParam = "directvolumemigrationprogress" DirectVolumeProgressesRoot = Root + "/directvolumemigrationprogresses" DirectVolumeProgressRoot = DirectVolumeProgressesRoot + "/:" + DirectVolumeProgressParam )
const ( EventInvolvedUIDParam = "involvedobjectuid" EventsRoot = Root + "/events" EventRoot = EventsRoot + "/:" + EventInvolvedUIDParam )
const ( HookParam = "hook" HooksRoot = Root + "/hooks" HookRoot = HooksRoot + "/:" + HookParam )
const ( JobParam = "job" JobsRoot = NamespaceRoot + "/jobs" JobRoot = JobsRoot + "/:" + JobParam )
const ( MigrationParam = "migration" MigrationsRoot = Root + "/migrations" MigrationRoot = MigrationsRoot + "/:" + MigrationParam )
Migration route root.
const ( Ns2Param = "ns2" NamespacesRoot = ClusterRoot + "/namespaces" NamespaceRoot = NamespacesRoot + "/:" + Ns2Param )
const ( PlanParam = "plan" PlansRoot = Root + "/plans" PlanRoot = PlansRoot + "/:" + PlanParam TreeMigrationParam = "migration" PlanTreeRoot = PlanRoot + "/tree" PlanTreeMigrationRoot = PlanTreeRoot + "/:" + TreeMigrationParam )
Plan route root.
const ( PodParam = "pod" PodsRoot = NamespaceRoot + "/pods" PodRoot = PodsRoot + "/:" + PodParam LogRoot = PodRoot + "/log" )
const ( PvParam = "pv" PvsRoot = ClusterRoot + "/persistentvolumes" PvRoot = PvsRoot + "/:" + PvParam )
const ( PvBackupParam = "backup" PvBackupsRoot = NamespaceRoot + "/podvolumebackups" PvBackupRoot = PvBackupsRoot + "/:" + PvBackupParam )
PodVolumeBackup route root.
const ( PvcParam = "pvc" PvcsRoot = NamespaceRoot + "/persistentvolumeclaims" PvcRoot = PvcsRoot + "/:" + PvcParam )
const ( PvRestoreParam = "restore" PvRestoresRoot = NamespaceRoot + "/podvolumerestores" PvRestoreRoot = PvRestoresRoot + "/:" + PvRestoreParam )
PodVolumeRestore route root.
const ( RestoreParam = "restore" RestoresRoot = NamespaceRoot + "/restores" RestoreRoot = RestoresRoot + "/:" + RestoreParam )
Restore route root.
const ( RouteParam = "route" RoutesRoot = NamespaceRoot + "/routes" RouteRoot = RoutesRoot + "/:" + RouteParam )
const ( ServiceParam = "service" ServicesRoot = NamespaceRoot + "/services" ServiceRoot = ServicesRoot + "/:" + ServiceParam )
const ( StorageClassParam = "storageclass" StorageClasssRoot = ClusterRoot + "/storageclasses" StorageClassRoot = StorageClasssRoot + "/:" + StorageClassParam )
const ( VirtualMachineParam = "virtualmachine" VirtualMachinesRoot = NamespaceRoot + "/virtualmachines" VirtualMachineRoot = VirtualMachinesRoot + "/:" + VirtualMachineParam )
const ( NsParam = "ns1" NsCollection = "namespaces" Root = "/" + NsCollection + "/" + ":" + NsParam )
Root - all routes.
Variables ¶
var Settings = &settings.Settings
Application settings.
Functions ¶
This section is empty.
Types ¶
type Backup ¶
type Backup struct { // The k8s namespace. Namespace string `json:"namespace,omitempty"` // The k8s name. Name string `json:"name"` // Self URI. SelfLink string `json:"selfLink"` // Raw k8s object. Object *velero.Backup `json:"object,omitempty"` }
Backup REST resource.
type BackupHandler ¶
type BackupHandler struct { // Base ClusterScoped // contains filtered or unexported fields }
Backup (route) handler.
func (BackupHandler) List ¶
func (h BackupHandler) List(ctx *gin.Context)
List all of the backups in the namespace.
type BackupList ¶
type BackupList struct { // Total number in the collection. Count int64 `json:"count"` // List of resources. Items []Backup `json:"resources"` }
Backup collection REST resource.
type BaseHandler ¶
type BaseHandler struct {
// contains filtered or unexported fields
}
Base web request handler.
type Cluster ¶
type Cluster struct { // Cluster k8s namespace. Namespace string `json:"namespace,omitempty"` // Cluster k8s name. Name string `json:"name"` // Self URI. SelfLink string `json:"selfLink"` // Raw k8s object. Object *migapi.MigCluster `json:"object,omitempty"` }
Cluster REST resource.
type ClusterHandler ¶
type ClusterHandler struct { // Base ClusterScoped }
Cluster (route) handler.
func (ClusterHandler) List ¶
func (h ClusterHandler) List(ctx *gin.Context)
List clusters in the namespace.
type ClusterList ¶
type ClusterList struct { // Total number in the collection. Count int64 `json:"count"` // List of resources. Items []Cluster `json:"resources"` }
Cluster collection REST resource.
type ClusterScoped ¶
type ClusterScoped struct { // Base BaseHandler // contains filtered or unexported fields }
Base handler for cluster scoped routes.
type Container ¶
type Container struct { // Pod k8s name. Name string `json:"name"` // The URI used to obtain logs. Log string `json:"log"` }
Container REST resource.
type DirectImage ¶
type DirectImage struct { // The k8s namespace. Namespace string `json:"namespace,omitempty"` // The k8s name. Name string `json:"name"` // Self URI. SelfLink string `json:"selfLink"` // Raw k8s object. Object *migapi.DirectImageMigration `json:"object,omitempty"` }
DirectImage REST resource.
func (*DirectImage) With ¶
func (r *DirectImage) With(m *model.DirectImageMigration)
Build the resource.
type DirectImageList ¶
type DirectImageList struct { // Total number in the collection. Count int64 `json:"count"` // List of resources. Items []DirectImage `json:"resources"` }
DirectImage collection REST resource.
type DirectImageMigrationHandler ¶
type DirectImageMigrationHandler struct { // Base BaseHandler // contains filtered or unexported fields }
DirectImage (route) handler.
func (DirectImageMigrationHandler) AddRoutes ¶
func (h DirectImageMigrationHandler) AddRoutes(r *gin.Engine)
Add DIM routes.
func (DirectImageMigrationHandler) Get ¶
func (h DirectImageMigrationHandler) Get(ctx *gin.Context)
Get a specific dim.
func (DirectImageMigrationHandler) Link ¶
func (h DirectImageMigrationHandler) Link(m *model.DirectImageMigration) string
Build self link.
func (DirectImageMigrationHandler) List ¶
func (h DirectImageMigrationHandler) List(ctx *gin.Context)
List all of the dims in the namespace.
type DirectImageStream ¶
type DirectImageStream struct { // The k8s namespace. Namespace string `json:"namespace,omitempty"` // The k8s name. Name string `json:"name"` // Self URI. SelfLink string `json:"selfLink"` // Raw k8s object. Object *migapi.DirectImageStreamMigration `json:"object,omitempty"` }
DirectImageStream REST resource.
func (*DirectImageStream) With ¶
func (r *DirectImageStream) With(m *model.DirectImageStreamMigration)
Build the resource.
type DirectImageStreamList ¶
type DirectImageStreamList struct { // Total number in the collection. Count int64 `json:"count"` // List of resources. Items []DirectImageStream `json:"resources"` }
DirectImageStream collection REST resource.
type DirectImageStreamMigrationHandler ¶
type DirectImageStreamMigrationHandler struct { // Base BaseHandler // contains filtered or unexported fields }
DirectImageStreamMigration (route) handler.
func (DirectImageStreamMigrationHandler) AddRoutes ¶
func (h DirectImageStreamMigrationHandler) AddRoutes(r *gin.Engine)
Add DISM routes.
func (DirectImageStreamMigrationHandler) Get ¶
func (h DirectImageStreamMigrationHandler) Get(ctx *gin.Context)
Get a specific dism.
func (DirectImageStreamMigrationHandler) Link ¶
func (h DirectImageStreamMigrationHandler) Link(m *model.DirectImageStreamMigration) string
Build self link.
func (DirectImageStreamMigrationHandler) List ¶
func (h DirectImageStreamMigrationHandler) List(ctx *gin.Context)
List all of the disms in the namespace.
type DirectVolume ¶
type DirectVolume struct { // The k8s namespace. Namespace string `json:"namespace,omitempty"` // The k8s name. Name string `json:"name"` // Self URI. SelfLink string `json:"selfLink"` // Raw k8s object. Object *migapi.DirectVolumeMigration `json:"object,omitempty"` }
DirectVolume REST resource.
func (*DirectVolume) With ¶
func (r *DirectVolume) With(m *model.DirectVolumeMigration)
Build the resource.
type DirectVolumeList ¶
type DirectVolumeList struct { // Total number in the collection. Count int64 `json:"count"` // List of resources. Items []DirectVolume `json:"resources"` }
DirectVolume collection REST resource.
type DirectVolumeMigrationHandler ¶
type DirectVolumeMigrationHandler struct { // Base BaseHandler // contains filtered or unexported fields }
DirectVolume (route) handler.
func (DirectVolumeMigrationHandler) AddRoutes ¶
func (h DirectVolumeMigrationHandler) AddRoutes(r *gin.Engine)
Add DVM routes.
func (DirectVolumeMigrationHandler) Get ¶
func (h DirectVolumeMigrationHandler) Get(ctx *gin.Context)
Get a specific dvm.
func (DirectVolumeMigrationHandler) Link ¶
func (h DirectVolumeMigrationHandler) Link(m *model.DirectVolumeMigration) string
Build self link.
func (DirectVolumeMigrationHandler) List ¶
func (h DirectVolumeMigrationHandler) List(ctx *gin.Context)
List all of the dvms in the namespace.
type DirectVolumeMigrationProgressHandler ¶
type DirectVolumeMigrationProgressHandler struct { // Base BaseHandler // contains filtered or unexported fields }
DirectVolumeMigrationProgress (route) handler.
func (DirectVolumeMigrationProgressHandler) AddRoutes ¶
func (h DirectVolumeMigrationProgressHandler) AddRoutes(r *gin.Engine)
Add DVMP routes.
func (DirectVolumeMigrationProgressHandler) Get ¶
func (h DirectVolumeMigrationProgressHandler) Get(ctx *gin.Context)
Get a specific dvmp.
func (DirectVolumeMigrationProgressHandler) Link ¶
func (h DirectVolumeMigrationProgressHandler) Link(m *model.DirectVolumeMigrationProgress) string
Build self link.
func (DirectVolumeMigrationProgressHandler) List ¶
func (h DirectVolumeMigrationProgressHandler) List(ctx *gin.Context)
List all of the dvmps in the namespace.
type DirectVolumeProgress ¶
type DirectVolumeProgress struct { // The k8s namespace. Namespace string `json:"namespace,omitempty"` // The k8s name. Name string `json:"name"` // Self URI. SelfLink string `json:"selfLink"` // Raw k8s object. Object *migapi.DirectVolumeMigrationProgress `json:"object,omitempty"` }
DirectVolumeMigrationProgress REST resource.
func (*DirectVolumeProgress) With ¶
func (r *DirectVolumeProgress) With(m *model.DirectVolumeMigrationProgress)
Build the resource.
type DirectVolumeProgressList ¶
type DirectVolumeProgressList struct { // Total number in the collection. Count int64 `json:"count"` // List of resources. Items []DirectVolumeProgress `json:"resources"` }
DirectVolumeProgress collection REST resource.
type Event ¶
type Event struct { // The k8s namespace. Namespace string `json:"namespace,omitempty"` // The k8s name. Name string `json:"name"` // Self URI. SelfLink string `json:"selfLink"` // Raw k8s object. Object *v1.Event `json:"object,omitempty"` }
Event REST resource
type EventHandler ¶
type EventHandler struct { // Base BaseHandler }
Event (route) handler.
func (EventHandler) Get ¶
func (h EventHandler) Get(ctx *gin.Context)
Get Events for a particular involvedObject UID on a cluster.
func (EventHandler) List ¶
func (h EventHandler) List(ctx *gin.Context)
List all of the Events on a cluster.
type EventList ¶
type EventList struct { // Total number in the collection. Count int64 `json:"count"` // UID of involvedObject events were retrieved for UID string `json:"uid"` // List of resources. Items []Event `json:"resources"` }
Event collection REST resource.
type Hook ¶
type Hook struct { // The k8s namespace. Namespace string `json:"namespace,omitempty"` // The k8s name. Name string `json:"name"` // Self URI. SelfLink string `json:"selfLink"` // Raw k8s object. Object *migapi.MigHook `json:"object,omitempty"` }
Hook REST resource.
type HookHandler ¶
type HookHandler struct { // Base BaseHandler // contains filtered or unexported fields }
Hook (route) handler.
func (HookHandler) List ¶
func (h HookHandler) List(ctx *gin.Context)
List all of the dims in the namespace.
type HookList ¶
type HookList struct { // Total number in the collection. Count int64 `json:"count"` // List of resources. Items []Hook `json:"resources"` }
Hook collection REST resource.
type Job ¶
type Job struct { // The k8s namespace. Namespace string `json:"namespace,omitempty"` // The k8s name. Name string `json:"name"` // Self URI. SelfLink string `json:"selfLink"` // Raw k8s object. Object *batchv1.Job `json:"object,omitempty"` }
Job REST resource
type JobHandler ¶
type JobHandler struct { // Base ClusterScoped }
Job (route) handler.
func (JobHandler) List ¶
func (h JobHandler) List(ctx *gin.Context)
List all of the Jobs on a cluster.
type JobList ¶
type JobList struct { // Total number in the collection. Count int64 `json:"count"` // List of resources. Items []Job `json:"resources"` }
Job collection REST resource.
type LogHandler ¶
type LogHandler struct { // Base ClusterScoped }
Pod-log (route) handler.
func (LogHandler) List ¶
func (h LogHandler) List(ctx *gin.Context)
List all logs (entries) for a pod (and optional container).
type MigResource ¶
type MigResource interface { // Get a map containing the correlation label. // Correlation labels are used to track any resource // created by the controller. The includes the application // (global) label and the resource label. GetCorrelationLabels() map[string]string // Get the resource correlation label. // The label is used to track resources created by the // controller that is related to this resource. GetCorrelationLabel() (string, string) // Get the resource namespace. GetNamespace() string // Get the resource name. GetName() string // Mark the resource as having been reconciled. // Updates the ObservedDigest. // Update the touch annotation. This ensures that the resource // is changed on every reconcile. This needed to support // remote watch event propagation on OCP4. MarkReconciled() // Get whether the resource has been reconciled. HasReconciled() bool }
Migration application CR.
type Migration ¶
type Migration struct { // The k8s namespace. Namespace string `json:"namespace,omitempty"` // The k8s name. Name string `json:"name"` // Self URI. SelfLink string `json:"selfLink"` // Raw k8s object. Object *migapi.MigMigration `json:"object,omitempty"` }
Migration REST resource.
type MigrationHandler ¶
type MigrationHandler struct { // Base BaseHandler // contains filtered or unexported fields }
Migration (route) handler.
func (MigrationHandler) Get ¶
func (h MigrationHandler) Get(ctx *gin.Context)
Get a specific migration.
func (MigrationHandler) Link ¶
func (h MigrationHandler) Link(m *model.Migration) string
Build self link.
func (MigrationHandler) List ¶
func (h MigrationHandler) List(ctx *gin.Context)
List all of the migrations in the namespace.
type MigrationList ¶
type MigrationList struct { // Total number in the collection. Count int64 `json:"count"` // List of resources. Items []Migration `json:"resources"` }
Migration collection REST resource.
type Namespace ¶
type Namespace struct { // Cluster k8s namespace. Namespace string `json:"namespace,omitempty"` // Cluster k8s name. Name string `json:"name"` // Number of services. ServiceCount int64 `json:"serviceCount"` // Number of pods. PodCount int64 `json:"podCount"` // Number of PVCs. PvcCount int64 `json:"pvcCount"` // Number of Virtual Machines. VmCount int64 `json:"vmCount"` // Self URI. SelfLink string `json:"selfLink"` // Raw k8s object. Object *v1.Namespace `json:"object,omitempty"` }
Namespace REST resource
type NamespaceList ¶
type NamespaceList struct { // Total number in the collection. Count int64 `json:"count"` // List of resources. Items []Namespace `json:"resources"` }
NS collection REST resource.
type NsHandler ¶
type NsHandler struct { // Base ClusterScoped }
Namespaces (route) handler.
type PV ¶
type PV struct { // The k8s namespace. Namespace string `json:"namespace,omitempty"` // The k8s name. Name string `json:"name"` // Self URI. SelfLink string `json:"selfLink"` // Raw k8s object. Object *v1.PersistentVolume `json:"object,omitempty"` }
PV REST resource
type PVC ¶
type PVC struct { // The k8s namespace. Namespace string `json:"namespace,omitempty"` // The k8s name. Name string `json:"name"` // Self URI. SelfLink string `json:"selfLink"` // Raw k8s object. Object *v1.PersistentVolumeClaim `json:"object,omitempty"` }
PVC REST resource
type Plan ¶
type Plan struct { // The k8s namespace. Namespace string `json:"namespace,omitempty"` // The k8s name. Name string `json:"name"` // Self URI. SelfLink string `json:"selfLink"` // Raw k8s object. Object *migapi.MigPlan `json:"object,omitempty"` }
Plan REST resource.
type PlanHandler ¶
type PlanHandler struct { // Base BaseHandler // contains filtered or unexported fields }
Plan (route) handler.
func (PlanHandler) List ¶
func (h PlanHandler) List(ctx *gin.Context)
List all of the plans in the namespace.
func (PlanHandler) Pods ¶
func (h PlanHandler) Pods(ctx *gin.Context)
Get the `PlanPods` for the plan.
func (*PlanHandler) Prepare ¶
func (h *PlanHandler) Prepare(ctx *gin.Context) int
Prepare to fulfil the request. Fetch the referenced plan. Perform SAR authorization.
func (PlanHandler) Tree ¶
func (h PlanHandler) Tree(ctx *gin.Context)
Get a specific migration tree.
type PlanList ¶
type PlanList struct { // Total number in the collection. Count int64 `json:"count"` // List of resources. Items []Plan `json:"resources"` }
Plan collection REST resource.
type PlanPod ¶
type PlanPod struct { // Pod k8s namespace. Namespace string `json:"namespace"` // Pod k8s name. Name string `json:"name"` // List of containers. Containers []Container `json:"containers"` }
PlanPod REST resource.
type PlanPods ¶
type PlanPods struct { // The k8s namespace. Namespace string `json:"namespace"` // The k8s name. Name string `json:"name"` // List of controller pods. Controller []PlanPod `json:"controller"` // List of relevant pods on source cluster. Source []PlanPod `json:"source"` // List of relevant pods on the destination cluster. Destination []PlanPod `json:"destination"` }
PlanPods REST resource.
type Pod ¶
type Pod struct { // The k8s namespace. Namespace string `json:"namespace,omitempty"` // The k8s name. Name string `json:"name"` // Self URI. SelfLink string `json:"selfLink"` // Raw k8s object. Object *v1.Pod `json:"object,omitempty"` }
Pod REST resource
type PodHandler ¶
type PodHandler struct { // Base ClusterScoped }
Pod (route) handler.
func (PodHandler) List ¶
func (h PodHandler) List(ctx *gin.Context)
List pods on a cluster in a namespace.
type PodList ¶
type PodList struct { // Total number in the collection. Count int64 `json:"count"` // List of resources. Items []Pod `json:"resources"` }
Pod collection REST resource.
type PvBackup ¶
type PvBackup struct { // The k8s namespace. Namespace string `json:"namespace,omitempty"` // The k8s name. Name string `json:"name"` // Self URI. SelfLink string `json:"selfLink"` // Raw k8s object. Object *velero.PodVolumeBackup `json:"object,omitempty"` }
PodVolumeBackup REST resource.
type PvBackupHandler ¶
type PvBackupHandler struct { // Base ClusterScoped // contains filtered or unexported fields }
PodVolumeBackup (route) handler.
func (PvBackupHandler) Link ¶
func (h PvBackupHandler) Link(c *model.Cluster, m *model.PodVolumeBackup) string
Build self link.
func (PvBackupHandler) List ¶
func (h PvBackupHandler) List(ctx *gin.Context)
List all of the backups in the namespace.
type PvBackupList ¶
type PvBackupList struct { // Total number in the collection. Count int64 `json:"count"` // List of resources. Items []PvBackup `json:"resources"` }
PodVolumeBackup collection REST resource.
type PvHandler ¶
type PvHandler struct { // Base ClusterScoped }
PV (route) handler.
type PvList ¶
type PvList struct { // Total number in the collection. Count int64 `json:"count"` // List of resources. Items []PV `json:"resources"` }
PV collection REST resource.
type PvRestore ¶
type PvRestore struct { // The k8s namespace. Namespace string `json:"namespace,omitempty"` // The k8s name. Name string `json:"name"` // Self URI. SelfLink string `json:"selfLink"` // Raw k8s object. Object *velero.PodVolumeRestore `json:"object,omitempty"` }
PodVolumeRestore REST resource.
type PvRestoreHandler ¶
type PvRestoreHandler struct { // Base ClusterScoped // contains filtered or unexported fields }
PodVolumeRestore (route) handler.
func (PvRestoreHandler) Get ¶
func (h PvRestoreHandler) Get(ctx *gin.Context)
Get a specific restore.
func (PvRestoreHandler) Link ¶
func (h PvRestoreHandler) Link(c *model.Cluster, m *model.PodVolumeRestore) string
Build self link.
func (PvRestoreHandler) List ¶
func (h PvRestoreHandler) List(ctx *gin.Context)
List all of the restores in the namespace.
type PvRestoreList ¶
type PvRestoreList struct { // Total number in the collection. Count int64 `json:"count"` // List of resources. Items []PvRestore `json:"resources"` }
PodVolumeRestore collection REST resource.
type PvcHandler ¶
type PvcHandler struct { // Base ClusterScoped }
PVC (route) handler.
func (PvcHandler) List ¶
func (h PvcHandler) List(ctx *gin.Context)
List all of the PVCs on a cluster.
type PvcList ¶
type PvcList struct { // Total number in the collection. Count int64 `json:"count"` // List of resources. Items []PVC `json:"resources"` }
PVC collection REST resource.
type RequestHandler ¶
type RequestHandler interface { // Add routes to the `gin` router. AddRoutes(*gin.Engine) // List resources in a REST collection. List(*gin.Context) // Get a specific REST resource. Get(*gin.Context) }
Web request handler.
type Restore ¶
type Restore struct { // The k8s namespace. Namespace string `json:"namespace,omitempty"` // The k8s name. Name string `json:"name"` // Raw k8s object. Object *velero.Restore `json:"object,omitempty"` // Self URI. SelfLink string `json:"selfLink"` }
Restore REST resource.
type RestoreHandler ¶
type RestoreHandler struct { // Base ClusterScoped // contains filtered or unexported fields }
Restore (route) handler.
func (RestoreHandler) List ¶
func (h RestoreHandler) List(ctx *gin.Context)
List all of the restores in the namespace.
type RestoreList ¶
type RestoreList struct { // Total number in the collection. Count int64 `json:"count"` // List of resources. Items []Restore `json:"resources"` }
Restore collection REST resource.
type RootNsHandler ¶
type RootNsHandler struct { // Base BaseHandler }
Root namespace (route) handler.
func (RootNsHandler) AddRoutes ¶
func (h RootNsHandler) AddRoutes(r *gin.Engine)
func (RootNsHandler) List ¶
func (h RootNsHandler) List(ctx *gin.Context)
List all root level namespaces.
type Route ¶
type Route struct { // The k8s namespace. Namespace string `json:"namespace,omitempty"` // The k8s name. Name string `json:"name"` // Self URI. SelfLink string `json:"selfLink"` // Raw k8s object. Object *v1.Route `json:"object,omitempty"` }
Route REST resource
type RouteHandler ¶
type RouteHandler struct { // Base ClusterScoped }
Route (route) handler.
func (RouteHandler) List ¶
func (h RouteHandler) List(ctx *gin.Context)
List routes on a cluster in a namespace.
type RouteList ¶
type RouteList struct { // Total number in the collection. Count int64 `json:"count"` // List of resources. Items []Route `json:"resources"` }
Route collection REST resource.
type SchemaHandler ¶
type SchemaHandler struct {
// contains filtered or unexported fields
}
Schema (route) handler.
func (SchemaHandler) AddRoutes ¶
func (h SchemaHandler) AddRoutes(r *gin.Engine)
type Service ¶
type Service struct { // The k8s namespace. Namespace string `json:"namespace,omitempty"` // The k8s name. Name string `json:"name"` // Self URI. SelfLink string `json:"selfLink"` // Raw k8s object. Object *v1.Service `json:"object,omitempty"` }
Service REST resource
type ServiceHandler ¶
type ServiceHandler struct { // Base ClusterScoped }
Service (route) handler.
func (ServiceHandler) Get ¶
func (h ServiceHandler) Get(ctx *gin.Context)
Get a specific Service on a cluster.
func (ServiceHandler) List ¶
func (h ServiceHandler) List(ctx *gin.Context)
List all of the Services on a cluster.
type ServiceList ¶
type ServiceList struct { // Total number in the collection. Count int64 `json:"count"` // List of resources. Items []Service `json:"resources"` }
Service collection REST resource.
type StorageClass ¶
type StorageClass struct { // The k8s namespace. Namespace string `json:"namespace,omitempty"` // The k8s name. Name string `json:"name"` // Self URI. SelfLink string `json:"selfLink"` // Raw k8s object. Object *v1.StorageClass `json:"object,omitempty"` }
StorageClass REST resource
type StorageClassHandler ¶
type StorageClassHandler struct { // Base ClusterScoped }
StorageClass (route) handler.
func (StorageClassHandler) AddRoutes ¶
func (h StorageClassHandler) AddRoutes(r *gin.Engine)
Add routes.
func (StorageClassHandler) Get ¶
func (h StorageClassHandler) Get(ctx *gin.Context)
Get a specific StorageClass on a cluster.
func (StorageClassHandler) Link ¶
func (h StorageClassHandler) Link(c *model.Cluster, m *model.StorageClass) string
Build self link.
func (StorageClassHandler) List ¶
func (h StorageClassHandler) List(ctx *gin.Context)
List all of the StorageClasss on a cluster.
type StorageClassList ¶
type StorageClassList struct { // Total number in the collection. Count int64 `json:"count"` // List of resources. Items []StorageClass `json:"resources"` }
StorageClass collection REST resource.
type TreeNode ¶
type TreeNode struct { Kind string `json:"kind"` Namespace string `json:"namespace"` Name string `json:"name"` ClusterType string `json:"clusterType"` Children []TreeNode `json:"children,omitempty"` ObjectLink string `json:"objectLink"` }
Tree node.
type VirtualMachine ¶
type VirtualMachine struct { // The k8s namespace. Namespace string `json:"namespace,omitempty"` // The k8s name. Name string `json:"name"` // Self URI. SelfLink string `json:"selfLink"` // Raw k8s object. Object *virtv1.VirtualMachine `json:"object,omitempty"` }
VirtualMachine REST resource
func (*VirtualMachine) With ¶
func (r *VirtualMachine) With(m *model.VirtualMachine)
Build the resource.
type VirtualMachineHandler ¶
type VirtualMachineHandler struct { // Base ClusterScoped }
Virtual Machine (route) handler.
func (VirtualMachineHandler) AddRoutes ¶
func (h VirtualMachineHandler) AddRoutes(r *gin.Engine)
Add routes.
func (VirtualMachineHandler) Get ¶
func (h VirtualMachineHandler) Get(ctx *gin.Context)
Get a specific Virtual Machine on a cluster.
func (VirtualMachineHandler) Link ¶
func (h VirtualMachineHandler) Link(c *model.Cluster, m *model.VirtualMachine) string
Build self link.
func (VirtualMachineHandler) List ¶
func (h VirtualMachineHandler) List(ctx *gin.Context)
List all of the VirtualMachines on a cluster.
type VirtualMachineList ¶
type VirtualMachineList struct { // Total number in the collection. Count int64 `json:"count"` // List of resources. Items []VirtualMachine `json:"resources"` }
Virtual Machine collection REST resource.