Documentation ¶
Overview ¶
Package tenantnamespace provides an interface, and its implementation, to handle the creation and the management of tenant namespaces
Index ¶
Constants ¶
View Source
const (
// NamePrefix is the prefix of all tenant namespace names.
NamePrefix = "liqo-tenant"
)
Variables ¶
This section is empty.
Functions ¶
func GetNameForNamespace ¶ added in v0.4.0
func GetNameForNamespace(cluster discoveryv1alpha1.ClusterIdentity) string
GetNameForNamespace given a cluster identity it returns the name of the tenant namespace for the cluster.
Types ¶
type Manager ¶
type Manager interface { CreateNamespace(ctx context.Context, cluster discoveryv1alpha1.ClusterIdentity) (*v1.Namespace, error) GetNamespace(ctx context.Context, cluster discoveryv1alpha1.ClusterIdentity) (*v1.Namespace, error) BindClusterRoles(ctx context.Context, cluster discoveryv1alpha1.ClusterIdentity, clusterRoles ...*rbacv1.ClusterRole) ([]*rbacv1.RoleBinding, error) UnbindClusterRoles(ctx context.Context, cluster discoveryv1alpha1.ClusterIdentity, clusterRoles ...string) error }
Manager provides the methods to handle the creation and the management of tenant namespaces.
func NewCachedManager ¶ added in v0.5.3
func NewCachedManager(ctx context.Context, client kubernetes.Interface) Manager
NewCachedManager creates a new TenantNamespaceManager object, supporting cached retrieval of namespaces for increased efficiency.
func NewManager ¶ added in v0.5.3
func NewManager(client kubernetes.Interface) Manager
NewManager creates a new TenantNamespaceManager object.
Click to show internal directories.
Click to hide internal directories.