Versions in this module Expand all Collapse all v1 v1.0.2 Sep 3, 2018 Changes in this version + const ZeroUUID + var StandardVolumeFilter = database.VolumeFilter + func CheckTariff(tariff billing.Tariff, isAdmin bool) error + func IsAdminRole(ctx context.Context) bool + type Clients struct + Billing clients.BillingClient + KubeAPI clients.KubeAPIClient + func (c *Clients) Close() error + type Server struct + func NewServer(db database.DB, clients *Clients) *Server + func (s *Server) AdminResizeVolume(ctx context.Context, nsID, label string, newCapacity int) error + func (s *Server) CreateStorage(ctx context.Context, storage model.Storage) error + func (s *Server) CreateVolume(ctx context.Context, nsID string, req model.VolumeCreateRequest) error + func (s *Server) DeleteAllNamespaceVolumes(ctx context.Context, nsID string) error + func (s *Server) DeleteAllUserVolumes(ctx context.Context) error + func (s *Server) DeleteStorage(ctx context.Context, name string) error + func (s *Server) DeleteVolume(ctx context.Context, nsID, label string) error + func (s *Server) DirectCreateVolume(ctx context.Context, nsID string, req model.DirectVolumeCreateRequest) error + func (s *Server) GetAllVolumes(ctx context.Context, page, perPage int, filters ...string) (kubeClientModel.VolumesList, error) + func (s *Server) GetNamespaceVolumes(ctx context.Context, nsID string) (kubeClientModel.VolumesList, error) + func (s *Server) GetStorages(ctx context.Context) ([]model.Storage, error) + func (s *Server) GetUserVolumes(ctx context.Context) (kubeClientModel.VolumesList, error) + func (s *Server) GetVolume(ctx context.Context, nsID, label string) (kubeClientModel.Volume, error) + func (s *Server) ImportVolume(ctx context.Context, nsID string, req kubeClientModel.Volume) error + func (s *Server) ResizeVolume(ctx context.Context, nsID, label string, newTariffID string) error + func (s *Server) UpdateStorage(ctx context.Context, name string, req model.UpdateStorageRequest) error + type StorageActions interface + CreateStorage func(ctx context.Context, storage model.Storage) error + DeleteStorage func(ctx context.Context, name string) error + GetStorages func(ctx context.Context) ([]model.Storage, error) + UpdateStorage func(ctx context.Context, name string, req model.UpdateStorageRequest) error + type VolumeActions interface + AdminResizeVolume func(ctx context.Context, nsID, label string, newCapacity int) error + CreateVolume func(ctx context.Context, nsID string, req model.VolumeCreateRequest) error + DeleteAllNamespaceVolumes func(ctx context.Context, nsID string) error + DeleteAllUserVolumes func(ctx context.Context) error + DeleteVolume func(ctx context.Context, nsID, label string) error + DirectCreateVolume func(ctx context.Context, nsID string, req model.DirectVolumeCreateRequest) error + GetAllVolumes func(ctx context.Context, page, perPage int, filters ...string) (kubeClientModel.VolumesList, error) + GetNamespaceVolumes func(ctx context.Context, nsID string) (kubeClientModel.VolumesList, error) + GetUserVolumes func(ctx context.Context) (kubeClientModel.VolumesList, error) + GetVolume func(ctx context.Context, nsID, label string) (kubeClientModel.Volume, error) + ImportVolume func(ctx context.Context, nsID string, req kubeClientModel.Volume) error + ResizeVolume func(ctx context.Context, nsID, label string, newTariffID string) error