package namespace

import "github.com/oslokommune/okctl/pkg/kube/manifests/namespace"

Package namespace provides a namespace creator and applier

Index

Types

type Namespace

type Namespace struct {
	Namespace string
	Labels    map[string]string
	Ctx       context.Context
}

Namespace contains the state for creating a namespace

func New

func New(namespace string, labels map[string]string) *Namespace

New returns an initialised namespace creator

func (*Namespace) CreateNamespace

func (n *Namespace) CreateNamespace(clientset kubernetes.Interface, _ *rest.Config) (interface{}, error)

CreateNamespace creates the namespace

func (*Namespace) DeleteNamespace

func (n *Namespace) DeleteNamespace(_ kubernetes.Interface, config *rest.Config) (interface{}, error)

DeleteNamespace deletes the namespace

func (*Namespace) NamespaceManifest

func (n *Namespace) NamespaceManifest() *v1.Namespace

NamespaceManifest returns the namespace manifest

Source Files

namespace.go

Version
v0.0.106 (latest)
Published
Oct 21, 2022
Platform
linux/amd64
Imports
5 packages
Last checked
18 hours ago

Tools for package owners.