
Welcome to Django Kubernetes Managerβs documentation!ΒΆ
Django Kubernetes Manager is an open source project to wrap the complexity of Kubernetes management in the simplicity of Django Rest Framework.
Documentation is (mostly) autogenerated, so if you notice anything that should be changed or added, please create a PR π
IntroductionΒΆ
Our engineering team has developed several data processing apps, and found celery wasnβt quite enough for dispatching heavier tasks. We decided to try Kubernetes Jobs, and while pleased with performance, wanted a less verbose, more object oriented way to interact with our clusters.
And thus Django Kubernetes Manager was spawned. Using Django Rest Framework and the kubernetes client library, our devs came up with the idea to treat each object weβd be deploying as a Model instance, and use the DRF viewsets and actions to create an RESTful API framework from which we could extend for each projects particular needs.
Table of ContentsΒΆ
Getting StartedΒΆ
QuickstartΒΆ
Install from PyPi
pip install django-kubernetes-manager
In settings.py (or module) add the app
INSTALLED_APPS = [
... ,
rest_framework,
kubernetes_manager,
]
In urls.py include the package urls
urlpatterns = [
... ,
path('dkm/', include('kubernetes_manager.urls')),
]
Run migrations and start server
./manage.py migrate
./manage.py runserver
Navigate to django admin and create a TargetCluster
Sample request
curl http://127.0.0.1:8000/dkm/api/namespaces/?format=json
[
{
"title": "veridian-dynamics-aerodynamic-bagels",
"description": null,
"cluster": "http://127.0.0.1:8000/dkm/api/clusters/1/?format=json",
"config": {},
"labels": {
"project": "aerodynamic-bagels",
"organization": "veridian-dynamics"
},
"annotations": {},
"api_version": "v1",
"kind": "Namespace",
"exists": true
}
]
Sample Use-casesΒΆ
Creating a labelled namespace for a client project:
from kubernetes_manager.models import KubernetesNamespace, TargetCluster
from django.db import models
from django_extensions.models import TitleDescriptionModel
class AppNamespace(TitleDescriptionModel):
project = models.OneToOneField("client.Project", on_delete=models.CASCADE)
organization = models.ForeignKey("client.Org", on_delete=models.CASCADE)
cluster = models.ForeignKey("kubernetes_manager.TargetCluster", on_delete=models.CASCADE)
namespace = models.ForeignKey("kubernetes_manager.KubernetesNamespace", null=True, blank=True, on_delete=models.CASCADE)
status = models.CharField(max_length = 128, null=True, blank=True)
def save(self, *args, **kwargs):
if not self.status == "{'phase': 'Active'}":
self.namespace = KubernetesNamespace.objects.create(
title = "ns-" + self.organization.slug + "-" + self.project.slug,
cluster = self.cluster,
labels = {"organization":self.organization.slug, "project": self.project.slug},
kind = "Namespace"
)
self.status = self.namespace.deploy()
super().save(*args, **kwargs)
def remove(self, *args, **kwargs):
self.status = self.namespace.k_delete()
def delete(self, *args, **kwargs):
self.remove()
super().delete(*args, **kwargs)
Creating a two-container deployment:
from kubernetes_manager.models import KubernetesNamespace, TargetCluster
from django.db import models
from django_extensions.models import TitleDescriptionModel
from .ns import AppNamespace
class FileServer(TitleDescriptionModel):
name = models.CharField(max_length=128)
organization = models.ForeignKey("client.Org", on_delete=models.CASCADE)
project = models.ForeignKey("client.Project", on_delete=models.CASCADE)
cluster = models.ForeignKey("kubernetes_manager.TargetCluster", on_delete=models.CASCADE)
namespace = models.ForeignKey(AppNamespace, on_delete=models.CASCADE)
file = models.ForeignKey("library.FileItem", on_delete=models.CASCADE)
docker_image = models.CharField(max_length=256, help_text="Docker repo path for image")
docker_tag = models.CharField(max_length=16, help_text="Docker tag for image")
definition = JSONField(null=True, blank=True)
# define volume
def vol(self, *args, **kwargs):
volume = KubernetesVolume.objects.create(
title = self.name + "-vol",
cluster = self.cluster
)
return volume
# create primary container
def container_spec(self, *args, **kwargs):
container = KubernetesContainer.objects.create(
title = self.name,
cluster = self.cluster,
image_name = self.docker_image,
image_tag = self.docker_tag,
volume_mount = KubernetesVolumeMount.objects.create(
title = self.name + "-vol",
cluster = self.cluster
) if not kwargs.get("mount", None) else kwargs.get("mount"),
command = "ls",
args ="/media"
)
return container
# create download sidecar
def sidecar_spec(self, *args, **kwargs):
sidecar = KubernetesContainer.objects.create(
title = self.name,
cluster = self.cluster,
image_name = "curlimages/curl",
image_tag = "7.69.1",
volume_mount = KubernetesVolumeMount.objects.create(
title = self.name + "-vol",
cluster = self.cluster
) if not kwargs.get("mount", None) else kwargs.get("mount"),
command = "/bin/sh",
args = '-c,curl -oL {} {}'.format(self.file.name, self.file.url)
)
return sidecar
# create pod template
def pod_template_spec(self, *args, **kwargs):
volume_mount = KubernetesVolumeMount.objects.create(
title = self.name + "-vol",
cluster = self.cluster
)
pod = KubernetesPodTemplate.objects.create(
title = self.name,
cluster = self.cluster,
volume = self.vol(),
primary_container = self.container_spec(mount=volume_mount),
secondary_container = self.sidecar_spec(mount=volume_mount),
restart_policy = "Always",
labels = {"project": self.project.slug}
)
return pod
# tie it up and deplioy
def deploy(self):
pod = self.pod_template_spec()
deployment = KubernetesDeployment.objects.create(
title = self.name,
cluster = self.cluster,
api_version = "apps/v1",
kind = "Deployment",
namespace = self.namespace.namespace.slug,
labels = {"project": self.project.slug},
selector = {"project": self.project.slug},
pod_template = pod
)
self.definition = deployment.get_obj().to_dict()
self.save()
return deployment.deploy()
ModelsΒΆ
Base ModelsΒΆ
-
class
kubernetes_manager.models.base.
KubernetesBase
(*args, **kwargs)ΒΆ Bases:
django_extensions.db.models.TitleSlugDescriptionModel
- Type
model (abstract)
- Description
Base parent model that all subsequent models inherit from.
- Inherits
django_extensions.db.models.TitleSlugDescriptionModel
- Fields
id, cluster, config, deployed, deleted
- Parameters
title (CharField) β Title
description (TextField) β Description
slug (AutoSlugField) β Slug
id (UUIDField) β UUID Auto field.
cluster_id (ForeignKey) β ForeignKey to TargetCluster object.
config (JSONField) β Pass in extra parameters here.
deployed (DateTimeField) β Time when object is applied to cluster.
removed (DateTimeField) β Time when object is removed from cluster.
-
cluster
ΒΆ Accessor to the related object on the forward side of a many-to-one or one-to-one (via ForwardOneToOneDescriptor subclass) relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Child.parent
is aForwardManyToOneDescriptor
instance.
-
cluster_id
ΒΆ
-
config
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
deployed
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
get_client
(API=<class 'kubernetes.client.apis.core_v1_api.CoreV1Api'>, **kwargs)ΒΆ Gets a k8s api client
- Args:
API (client.<type>) - Kubernetes Client Type
- Returns:
object of type <API>
-
id
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
removed
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
slugify_function
(content)ΒΆ - Description
Overrides default slugify with custom logic.
-
class
kubernetes_manager.models.base.
KubernetesMetadataObjBase
(*args, **kwargs)ΒΆ Bases:
kubernetes_manager.models.base.KubernetesBase
- Type
model (abstract)
- Description
Extends KubernetesBase to include metadata fields.
- Inherits
kubernetes_manager.models.base.KubernetesBase
- Fields
labels, annotations
- Parameters
title (CharField) β Title
description (TextField) β Description
slug (AutoSlugField) β Slug
id (UUIDField) β UUID Auto field.
cluster_id (ForeignKey) β ForeignKey to TargetCluster object.
config (JSONField) β Pass in extra parameters here.
deployed (DateTimeField) β Time when object is applied to cluster.
removed (DateTimeField) β Time when object is removed from cluster.
labels (JSONField) β Dictionary store equivalent to Labels in Kubernetes API
annotations (JSONField) β Dictionary store equivalent to Annotations in Kubernetes API
-
annotations
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
cluster
ΒΆ Accessor to the related object on the forward side of a many-to-one or one-to-one (via ForwardOneToOneDescriptor subclass) relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Child.parent
is aForwardManyToOneDescriptor
instance.
-
labels
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
class
kubernetes_manager.models.base.
KubernetesNetworkingBase
(*args, **kwargs)ΒΆ Bases:
kubernetes_manager.models.base.KubernetesMetadataObjBase
- Type
model (abstract)
- Description
Extends KubernetesMetadataObjBase to include network fields.
- Inherits
kubernetes_manager.models.base.KubernetesMetadataObjBase
- Fields
labels, annotations
- Parameters
title (CharField) β Title
description (TextField) β Description
slug (AutoSlugField) β Slug
id (UUIDField) β UUID Auto field.
cluster_id (ForeignKey) β ForeignKey to TargetCluster object.
config (JSONField) β Pass in extra parameters here.
deployed (DateTimeField) β Time when object is applied to cluster.
removed (DateTimeField) β Time when object is removed from cluster.
labels (JSONField) β Dictionary store equivalent to Labels in Kubernetes API
annotations (JSONField) β Dictionary store equivalent to Annotations in Kubernetes API
api_version (CharField) β API version used to deploy child object.
kind (CharField) β String representation of Kubernetes object kind
port (IntegerField) β Port object will expose
namespace_id (ForeignKey) β Live namespace the object is associated with.
kuid (CharField) β Objectβs UID in the cluster
-
api_version
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
cluster
ΒΆ Accessor to the related object on the forward side of a many-to-one or one-to-one (via ForwardOneToOneDescriptor subclass) relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Child.parent
is aForwardManyToOneDescriptor
instance.
-
kind
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
kuid
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
namespace
ΒΆ Accessor to the related object on the forward side of a many-to-one or one-to-one (via ForwardOneToOneDescriptor subclass) relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Child.parent
is aForwardManyToOneDescriptor
instance.
-
namespace_id
ΒΆ
-
port
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
Kubernetes ModelsΒΆ
-
class
kubernetes_manager.models.kube.
KubernetesConfigMap
(*args, **kwargs)ΒΆ Bases:
kubernetes_manager.models.base.KubernetesMetadataObjBase
- Type
model
- Description
Holds data related to a kubernetes volume mount.
- Inherits
kubernetes_manager.models.base.KubernetesMetadataObjBase
- Fields
kind, data, binary, override_name, namespace
- Parameters
title (CharField) β Title
description (TextField) β Description
slug (AutoSlugField) β Slug
id (UUIDField) β UUID Auto field.
cluster_id (ForeignKey) β ForeignKey to TargetCluster object.
config (JSONField) β Pass in extra parameters here.
deployed (DateTimeField) β Time when object is applied to cluster.
removed (DateTimeField) β Time when object is removed from cluster.
labels (JSONField) β Dictionary store equivalent to Labels in Kubernetes API
annotations (JSONField) β Dictionary store equivalent to Annotations in Kubernetes API
kind (CharField) β Kind
data (JSONField) β Data
binary (BinaryField) β Binary
override_name (CharField) β Override name
namespace_id (ForeignKey) β Namespace
-
exception
DoesNotExist
ΒΆ Bases:
django.core.exceptions.ObjectDoesNotExist
-
exception
MultipleObjectsReturned
ΒΆ Bases:
django.core.exceptions.MultipleObjectsReturned
-
binary
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
cluster
ΒΆ Accessor to the related object on the forward side of a many-to-one or one-to-one (via ForwardOneToOneDescriptor subclass) relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Child.parent
is aForwardManyToOneDescriptor
instance.
-
data
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
deploy
()ΒΆ - Description
Deploy configmap obj.
-
get_obj
()ΒΆ - Description
Generate configmap spec.
-
kind
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
namespace
ΒΆ Accessor to the related object on the forward side of a many-to-one or one-to-one (via ForwardOneToOneDescriptor subclass) relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Child.parent
is aForwardManyToOneDescriptor
instance.
-
namespace_id
ΒΆ
-
objects
= <django.db.models.manager.Manager object>ΒΆ
-
override_name
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
remove
()ΒΆ - Description
Delete configmap from namespace.
-
class
kubernetes_manager.models.kube.
KubernetesContainer
(*args, **kwargs)ΒΆ Bases:
kubernetes_manager.models.base.KubernetesBase
- Type
model
- Description
Holds data related to a kubernetes contaienr.
- Inherits
kubernetes_manager.models.base.KubernetesBase
- Fields
image_name, image_tag, image_pull_policy, command, args, port, volume_mount
- Parameters
title (CharField) β Title
description (TextField) β Description
slug (AutoSlugField) β Slug
id (UUIDField) β UUID Auto field.
cluster_id (ForeignKey) β ForeignKey to TargetCluster object.
config (JSONField) β Pass in extra parameters here.
deployed (DateTimeField) β Time when object is applied to cluster.
removed (DateTimeField) β Time when object is removed from cluster.
image_name (CharField) β Properly qualified image name.
image_tag (CharField) β Tag name for the image to be used for this job
image_pull_policy (CharField) β Image pull policy
command (TextField) β Command to run when start container
args (TextField) β Comma separated args to run with command when instantiating container.
port (IntegerField) β Port to expose.
volume_mounts (ManyToManyField) β Mounts for any number of volumes
-
exception
DoesNotExist
ΒΆ Bases:
django.core.exceptions.ObjectDoesNotExist
-
exception
MultipleObjectsReturned
ΒΆ Bases:
django.core.exceptions.MultipleObjectsReturned
-
args
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
cluster
ΒΆ Accessor to the related object on the forward side of a many-to-one or one-to-one (via ForwardOneToOneDescriptor subclass) relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Child.parent
is aForwardManyToOneDescriptor
instance.
-
command
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
get_image_pull_policy_display
(*, field=<django.db.models.fields.CharField: image_pull_policy>)ΒΆ
-
get_obj
()ΒΆ - Description
Generate container spec.
-
image_name
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
image_pull_policy
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
image_tag
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
kubernetespodtemplate_set
ΒΆ Accessor to the related objects manager on the forward and reverse sides of a many-to-many relation.
In the example:
class Pizza(Model): toppings = ManyToManyField(Topping, related_name='pizzas')
Pizza.toppings
andTopping.pizzas
areManyToManyDescriptor
instances.Most of the implementation is delegated to a dynamically defined manager class built by
create_forward_many_to_many_manager()
defined below.
-
objects
= <django.db.models.manager.Manager object>ΒΆ
-
port
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
volume_mounts
ΒΆ Accessor to the related objects manager on the forward and reverse sides of a many-to-many relation.
In the example:
class Pizza(Model): toppings = ManyToManyField(Topping, related_name='pizzas')
Pizza.toppings
andTopping.pizzas
areManyToManyDescriptor
instances.Most of the implementation is delegated to a dynamically defined manager class built by
create_forward_many_to_many_manager()
defined below.
-
class
kubernetes_manager.models.kube.
KubernetesDeployment
(*args, **kwargs)ΒΆ Bases:
kubernetes_manager.models.base.KubernetesNetworkingBase
,kubernetes_manager.models.mixins.KubernetesTelemetryMixin
- Type
model
- Description
Holds data related to a kubernetes deployment.
- Inherits
kubernetes_manager.models.base.KubernetesNetworkingBase, kubernetes_manager.models.base.KubernetesTelemetryMixin
- Fields
selector, replicas, pod_template
- Parameters
title (CharField) β Title
description (TextField) β Description
slug (AutoSlugField) β Slug
id (UUIDField) β UUID Auto field.
cluster_id (ForeignKey) β ForeignKey to TargetCluster object.
config (JSONField) β Pass in extra parameters here.
deployed (DateTimeField) β Time when object is applied to cluster.
removed (DateTimeField) β Time when object is removed from cluster.
labels (JSONField) β Dictionary store equivalent to Labels in Kubernetes API
annotations (JSONField) β Dictionary store equivalent to Annotations in Kubernetes API
api_version (CharField) β API version used to deploy child object.
kind (CharField) β String representation of Kubernetes object kind
port (IntegerField) β Port object will expose
namespace_id (ForeignKey) β Live namespace the object is associated with.
kuid (CharField) β Objectβs UID in the cluster
object_status (CharField) β status of the object in Kubernetes
average_cpu_usage (DecimalField) β Average PIT CPU units consumed
average_mem_usage (IntegerField) β Average PIT bytes consumed
cpu_usage_seconds (DecimalField) β Average cpu usage * seconds live
mem_usage_seconds (IntegerField) β Average mem usage * seconds live
selector (JSONField) β Selector
replicas (IntegerField) β Replicas
pod_template_id (ForeignKey) β Pod template
-
exception
DoesNotExist
ΒΆ Bases:
django.core.exceptions.ObjectDoesNotExist
-
exception
MultipleObjectsReturned
ΒΆ Bases:
django.core.exceptions.MultipleObjectsReturned
-
cluster
ΒΆ Accessor to the related object on the forward side of a many-to-one or one-to-one (via ForwardOneToOneDescriptor subclass) relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Child.parent
is aForwardManyToOneDescriptor
instance.
-
deploy
()ΒΆ - Description
Deploy deployment obj.
-
get_obj
()ΒΆ - Description
Generate Deployment spec.
-
namespace
ΒΆ Accessor to the related object on the forward side of a many-to-one or one-to-one (via ForwardOneToOneDescriptor subclass) relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Child.parent
is aForwardManyToOneDescriptor
instance.
-
objects
= <django.db.models.manager.Manager object>ΒΆ
-
pod_template
ΒΆ Accessor to the related object on the forward side of a many-to-one or one-to-one (via ForwardOneToOneDescriptor subclass) relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Child.parent
is aForwardManyToOneDescriptor
instance.
-
pod_template_id
ΒΆ
-
remove
()ΒΆ - Description
Remove deployment from namespace.
-
replicas
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
selector
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
class
kubernetes_manager.models.kube.
KubernetesIngress
(*args, **kwargs)ΒΆ Bases:
kubernetes_manager.models.base.KubernetesNetworkingBase
- Type
model
- Description
Holds data related to a kubernetes ingress.
- Inherits
kubernetes_manager.models.base.KubernetesNetworkingBase
- Fields
hostname, path, target_service
- Parameters
title (CharField) β Title
description (TextField) β Description
slug (AutoSlugField) β Slug
id (UUIDField) β UUID Auto field.
cluster_id (ForeignKey) β ForeignKey to TargetCluster object.
config (JSONField) β Pass in extra parameters here.
deployed (DateTimeField) β Time when object is applied to cluster.
removed (DateTimeField) β Time when object is removed from cluster.
labels (JSONField) β Dictionary store equivalent to Labels in Kubernetes API
annotations (JSONField) β Dictionary store equivalent to Annotations in Kubernetes API
api_version (CharField) β API version used to deploy child object.
kind (CharField) β String representation of Kubernetes object kind
port (IntegerField) β Port object will expose
namespace_id (ForeignKey) β Live namespace the object is associated with.
kuid (CharField) β Objectβs UID in the cluster
hostname (CharField) β Hostname
path (CharField) β Path
target_service_id (ForeignKey) β Target service
-
exception
DoesNotExist
ΒΆ Bases:
django.core.exceptions.ObjectDoesNotExist
-
exception
MultipleObjectsReturned
ΒΆ Bases:
django.core.exceptions.MultipleObjectsReturned
-
cluster
ΒΆ Accessor to the related object on the forward side of a many-to-one or one-to-one (via ForwardOneToOneDescriptor subclass) relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Child.parent
is aForwardManyToOneDescriptor
instance.
-
deploy
()ΒΆ - Description
Deploy ingress to ns.
-
get_obj
()ΒΆ - Description
Generate ingress obj.
-
hostname
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
namespace
ΒΆ Accessor to the related object on the forward side of a many-to-one or one-to-one (via ForwardOneToOneDescriptor subclass) relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Child.parent
is aForwardManyToOneDescriptor
instance.
-
objects
= <django.db.models.manager.Manager object>ΒΆ
-
path
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
remove
()ΒΆ - Description
Remove ingress from ns.
-
target_service
ΒΆ Accessor to the related object on the forward side of a many-to-one or one-to-one (via ForwardOneToOneDescriptor subclass) relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Child.parent
is aForwardManyToOneDescriptor
instance.
-
target_service_id
ΒΆ
-
class
kubernetes_manager.models.kube.
KubernetesJob
(*args, **kwargs)ΒΆ Bases:
kubernetes_manager.models.base.KubernetesNetworkingBase
,kubernetes_manager.models.mixins.KubernetesTelemetryMixin
- Type
model
- Description
Holds data related to a kubernetes pod spec.
- Inherits
kubernetes_manager.models.base.KubernetesNetworkingBase, kubernetes_manager.models.base.KubernetesTelemetryMixin
- Fields
selector, replicas, pod_template
- Parameters
title (CharField) β Title
description (TextField) β Description
slug (AutoSlugField) β Slug
id (UUIDField) β UUID Auto field.
cluster_id (ForeignKey) β ForeignKey to TargetCluster object.
config (JSONField) β Pass in extra parameters here.
deployed (DateTimeField) β Time when object is applied to cluster.
removed (DateTimeField) β Time when object is removed from cluster.
labels (JSONField) β Dictionary store equivalent to Labels in Kubernetes API
annotations (JSONField) β Dictionary store equivalent to Annotations in Kubernetes API
api_version (CharField) β API version used to deploy child object.
kind (CharField) β String representation of Kubernetes object kind
port (IntegerField) β Port object will expose
namespace_id (ForeignKey) β Live namespace the object is associated with.
kuid (CharField) β Objectβs UID in the cluster
object_status (CharField) β status of the object in Kubernetes
average_cpu_usage (DecimalField) β Average PIT CPU units consumed
average_mem_usage (IntegerField) β Average PIT bytes consumed
cpu_usage_seconds (DecimalField) β Average cpu usage * seconds live
mem_usage_seconds (IntegerField) β Average mem usage * seconds live
pod_template_id (ForeignKey) β Pod template
backoff_limit (IntegerField) β Backoff limit
-
exception
DoesNotExist
ΒΆ Bases:
django.core.exceptions.ObjectDoesNotExist
-
exception
MultipleObjectsReturned
ΒΆ Bases:
django.core.exceptions.MultipleObjectsReturned
-
backoff_limit
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
cluster
ΒΆ Accessor to the related object on the forward side of a many-to-one or one-to-one (via ForwardOneToOneDescriptor subclass) relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Child.parent
is aForwardManyToOneDescriptor
instance.
-
deploy
()ΒΆ - Description
Deploy job to ns.
-
get_obj
()ΒΆ - Description
Generate job spec.
-
namespace
ΒΆ Accessor to the related object on the forward side of a many-to-one or one-to-one (via ForwardOneToOneDescriptor subclass) relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Child.parent
is aForwardManyToOneDescriptor
instance.
-
objects
= <django.db.models.manager.Manager object>ΒΆ
-
pod_template
ΒΆ Accessor to the related object on the forward side of a many-to-one or one-to-one (via ForwardOneToOneDescriptor subclass) relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Child.parent
is aForwardManyToOneDescriptor
instance.
-
pod_template_id
ΒΆ
-
remove
()ΒΆ - Description
Remove job from ns.
-
class
kubernetes_manager.models.kube.
KubernetesNamespace
(*args, **kwargs)ΒΆ Bases:
kubernetes_manager.models.base.KubernetesMetadataObjBase
- Type
model
- Description
Holds data related to a Kubernetes namespace.
- Inherits
kubernetes_manager.models.base.KubernetesBase
- Fields
api_version, kind, exists
- Parameters
title (CharField) β Title
description (TextField) β Description
slug (AutoSlugField) β Slug
id (UUIDField) β UUID Auto field.
cluster_id (ForeignKey) β ForeignKey to TargetCluster object.
config (JSONField) β Pass in extra parameters here.
deployed (DateTimeField) β Time when object is applied to cluster.
removed (DateTimeField) β Time when object is removed from cluster.
labels (JSONField) β Dictionary store equivalent to Labels in Kubernetes API
annotations (JSONField) β Dictionary store equivalent to Annotations in Kubernetes API
api_version (CharField) β Api version
kind (CharField) β Kind
exists (BooleanField) β Exists
-
exception
DoesNotExist
ΒΆ Bases:
django.core.exceptions.ObjectDoesNotExist
-
exception
MultipleObjectsReturned
ΒΆ Bases:
django.core.exceptions.MultipleObjectsReturned
-
api_version
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
cluster
ΒΆ Accessor to the related object on the forward side of a many-to-one or one-to-one (via ForwardOneToOneDescriptor subclass) relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Child.parent
is aForwardManyToOneDescriptor
instance.
-
deploy
()ΒΆ - Description
Deploy namespace obj.
-
exists
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
get_obj
()ΒΆ - Description
Generate namespace spec.
-
kind
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
kubernetesconfigmap_set
ΒΆ Accessor to the related objects manager on the reverse side of a many-to-one relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Parent.children
is aReverseManyToOneDescriptor
instance.Most of the implementation is delegated to a dynamically defined manager class built by
create_forward_many_to_many_manager()
defined below.
-
kubernetesdeployment_set
ΒΆ Accessor to the related objects manager on the reverse side of a many-to-one relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Parent.children
is aReverseManyToOneDescriptor
instance.Most of the implementation is delegated to a dynamically defined manager class built by
create_forward_many_to_many_manager()
defined below.
-
kubernetesingress_set
ΒΆ Accessor to the related objects manager on the reverse side of a many-to-one relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Parent.children
is aReverseManyToOneDescriptor
instance.Most of the implementation is delegated to a dynamically defined manager class built by
create_forward_many_to_many_manager()
defined below.
-
kubernetesjob_set
ΒΆ Accessor to the related objects manager on the reverse side of a many-to-one relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Parent.children
is aReverseManyToOneDescriptor
instance.Most of the implementation is delegated to a dynamically defined manager class built by
create_forward_many_to_many_manager()
defined below.
-
kubernetesservice_set
ΒΆ Accessor to the related objects manager on the reverse side of a many-to-one relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Parent.children
is aReverseManyToOneDescriptor
instance.Most of the implementation is delegated to a dynamically defined manager class built by
create_forward_many_to_many_manager()
defined below.
-
objects
= <django.db.models.manager.Manager object>ΒΆ
-
remove
()ΒΆ - Description
Delete namespace from cluster.
-
class
kubernetes_manager.models.kube.
KubernetesPodTemplate
(*args, **kwargs)ΒΆ Bases:
kubernetes_manager.models.base.KubernetesMetadataObjBase
- Type
model
- Description
Holds data related to a kubernetes pod spec.
- Inherits
kubernetes_manager.models.base.KubernetesMetadataObjBase
- Fields
volume, primary_container, secondary_container, restart_policy
- Parameters
title (CharField) β Title
description (TextField) β Description
slug (AutoSlugField) β Slug
id (UUIDField) β UUID Auto field.
cluster_id (ForeignKey) β ForeignKey to TargetCluster object.
config (JSONField) β Pass in extra parameters here.
deployed (DateTimeField) β Time when object is applied to cluster.
removed (DateTimeField) β Time when object is removed from cluster.
labels (JSONField) β Dictionary store equivalent to Labels in Kubernetes API
annotations (JSONField) β Dictionary store equivalent to Annotations in Kubernetes API
restart_policy (CharField) β How the pod should handle restart om case of failures
volumes (ManyToManyField) β All volumes to be created for a pod.
containers (ManyToManyField) β All containers to be included in a pod.
-
exception
DoesNotExist
ΒΆ Bases:
django.core.exceptions.ObjectDoesNotExist
-
exception
MultipleObjectsReturned
ΒΆ Bases:
django.core.exceptions.MultipleObjectsReturned
-
cluster
ΒΆ Accessor to the related object on the forward side of a many-to-one or one-to-one (via ForwardOneToOneDescriptor subclass) relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Child.parent
is aForwardManyToOneDescriptor
instance.
-
containers
ΒΆ Accessor to the related objects manager on the forward and reverse sides of a many-to-many relation.
In the example:
class Pizza(Model): toppings = ManyToManyField(Topping, related_name='pizzas')
Pizza.toppings
andTopping.pizzas
areManyToManyDescriptor
instances.Most of the implementation is delegated to a dynamically defined manager class built by
create_forward_many_to_many_manager()
defined below.
-
get_obj
()ΒΆ - Description
Generate pod spec.
-
get_restart_policy_display
(*, field=<django.db.models.fields.CharField: restart_policy>)ΒΆ
-
kubernetesdeployment_set
ΒΆ Accessor to the related objects manager on the reverse side of a many-to-one relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Parent.children
is aReverseManyToOneDescriptor
instance.Most of the implementation is delegated to a dynamically defined manager class built by
create_forward_many_to_many_manager()
defined below.
-
kubernetesjob_set
ΒΆ Accessor to the related objects manager on the reverse side of a many-to-one relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Parent.children
is aReverseManyToOneDescriptor
instance.Most of the implementation is delegated to a dynamically defined manager class built by
create_forward_many_to_many_manager()
defined below.
-
objects
= <django.db.models.manager.Manager object>ΒΆ
-
restart_policy
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
volumes
ΒΆ Accessor to the related objects manager on the forward and reverse sides of a many-to-many relation.
In the example:
class Pizza(Model): toppings = ManyToManyField(Topping, related_name='pizzas')
Pizza.toppings
andTopping.pizzas
areManyToManyDescriptor
instances.Most of the implementation is delegated to a dynamically defined manager class built by
create_forward_many_to_many_manager()
defined below.
-
class
kubernetes_manager.models.kube.
KubernetesService
(*args, **kwargs)ΒΆ Bases:
kubernetes_manager.models.base.KubernetesNetworkingBase
- Type
model
- Description
Holds data related to a kubernetes service.
- Inherits
kubernetes_manager.models.base.KubernetesNetworkingBase
- Fields
selector, target_port
- Parameters
title (CharField) β Title
description (TextField) β Description
slug (AutoSlugField) β Slug
id (UUIDField) β UUID Auto field.
cluster_id (ForeignKey) β ForeignKey to TargetCluster object.
config (JSONField) β Pass in extra parameters here.
deployed (DateTimeField) β Time when object is applied to cluster.
removed (DateTimeField) β Time when object is removed from cluster.
labels (JSONField) β Dictionary store equivalent to Labels in Kubernetes API
annotations (JSONField) β Dictionary store equivalent to Annotations in Kubernetes API
api_version (CharField) β API version used to deploy child object.
kind (CharField) β String representation of Kubernetes object kind
port (IntegerField) β Port object will expose
namespace_id (ForeignKey) β Live namespace the object is associated with.
kuid (CharField) β Objectβs UID in the cluster
selector (JSONField) β Selector
target_port (IntegerField) β Target port
-
exception
DoesNotExist
ΒΆ Bases:
django.core.exceptions.ObjectDoesNotExist
-
exception
MultipleObjectsReturned
ΒΆ Bases:
django.core.exceptions.MultipleObjectsReturned
-
cluster
ΒΆ Accessor to the related object on the forward side of a many-to-one or one-to-one (via ForwardOneToOneDescriptor subclass) relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Child.parent
is aForwardManyToOneDescriptor
instance.
-
deploy
()ΒΆ - Description
Deploy service to ns.
-
get_obj
()ΒΆ - Description
Generate service spec.
-
kubernetesingress_set
ΒΆ Accessor to the related objects manager on the reverse side of a many-to-one relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Parent.children
is aReverseManyToOneDescriptor
instance.Most of the implementation is delegated to a dynamically defined manager class built by
create_forward_many_to_many_manager()
defined below.
-
namespace
ΒΆ Accessor to the related object on the forward side of a many-to-one or one-to-one (via ForwardOneToOneDescriptor subclass) relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Child.parent
is aForwardManyToOneDescriptor
instance.
-
objects
= <django.db.models.manager.Manager object>ΒΆ
-
remove
()ΒΆ - Description
Remove service from ns.
-
selector
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
target_port
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
class
kubernetes_manager.models.kube.
KubernetesVolume
(*args, **kwargs)ΒΆ Bases:
kubernetes_manager.models.base.KubernetesBase
- Type
model
- Description
Holds data related to a kubernetes volume.
- Inherits
kubernetes_manager.models.base.KubernetesBase
- Fields
- Parameters
title (CharField) β Title
description (TextField) β Description
slug (AutoSlugField) β Slug
id (UUIDField) β UUID Auto field.
cluster_id (ForeignKey) β ForeignKey to TargetCluster object.
config (JSONField) β Pass in extra parameters here.
deployed (DateTimeField) β Time when object is applied to cluster.
removed (DateTimeField) β Time when object is removed from cluster.
-
exception
DoesNotExist
ΒΆ Bases:
django.core.exceptions.ObjectDoesNotExist
-
exception
MultipleObjectsReturned
ΒΆ Bases:
django.core.exceptions.MultipleObjectsReturned
-
cluster
ΒΆ Accessor to the related object on the forward side of a many-to-one or one-to-one (via ForwardOneToOneDescriptor subclass) relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Child.parent
is aForwardManyToOneDescriptor
instance.
-
get_obj
()ΒΆ - Description
Generate volume spec.
-
kubernetespodtemplate_set
ΒΆ Accessor to the related objects manager on the forward and reverse sides of a many-to-many relation.
In the example:
class Pizza(Model): toppings = ManyToManyField(Topping, related_name='pizzas')
Pizza.toppings
andTopping.pizzas
areManyToManyDescriptor
instances.Most of the implementation is delegated to a dynamically defined manager class built by
create_forward_many_to_many_manager()
defined below.
-
objects
= <django.db.models.manager.Manager object>ΒΆ
-
class
kubernetes_manager.models.kube.
KubernetesVolumeMount
(*args, **kwargs)ΒΆ Bases:
kubernetes_manager.models.base.KubernetesBase
- Type
model
- Description
Holds data related to a kubernetes volume mount.
- Inherits
kubernetes_manager.models.base.KubernetesBase
- Fields
mount_path, sub_path
- Parameters
title (CharField) β Title
description (TextField) β Description
slug (AutoSlugField) β Slug
id (UUIDField) β UUID Auto field.
cluster_id (ForeignKey) β ForeignKey to TargetCluster object.
config (JSONField) β Pass in extra parameters here.
deployed (DateTimeField) β Time when object is applied to cluster.
removed (DateTimeField) β Time when object is removed from cluster.
mount_path (CharField) β Mount path
sub_path (CharField) β Sub path
-
exception
DoesNotExist
ΒΆ Bases:
django.core.exceptions.ObjectDoesNotExist
-
exception
MultipleObjectsReturned
ΒΆ Bases:
django.core.exceptions.MultipleObjectsReturned
-
cluster
ΒΆ Accessor to the related object on the forward side of a many-to-one or one-to-one (via ForwardOneToOneDescriptor subclass) relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Child.parent
is aForwardManyToOneDescriptor
instance.
-
get_obj
()ΒΆ - Description
Generate mount spec.
-
kubernetescontainer_set
ΒΆ Accessor to the related objects manager on the forward and reverse sides of a many-to-many relation.
In the example:
class Pizza(Model): toppings = ManyToManyField(Topping, related_name='pizzas')
Pizza.toppings
andTopping.pizzas
areManyToManyDescriptor
instances.Most of the implementation is delegated to a dynamically defined manager class built by
create_forward_many_to_many_manager()
defined below.
-
mount_path
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
objects
= <django.db.models.manager.Manager object>ΒΆ
-
sub_path
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
Kubernetes Model-MixinsΒΆ
-
class
kubernetes_manager.models.mixins.
KubernetesTelemetryMixin
(*args, **kwargs)ΒΆ Bases:
django.db.models.base.Model
- Type
mixin
- Description
Extends child model to include telemetry features.
- Inherits
django.db.models.Model
- Fields
object_status, average_cpu_usage, average_mem_usage, cpu_usage_seconds, mem_usage_seconds
- Parameters
object_status (CharField) β status of the object in Kubernetes
average_cpu_usage (DecimalField) β Average PIT CPU units consumed
average_mem_usage (IntegerField) β Average PIT bytes consumed
cpu_usage_seconds (DecimalField) β Average cpu usage * seconds live
mem_usage_seconds (IntegerField) β Average mem usage * seconds live
-
average_cpu_usage
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
average_mem_usage
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
cpu_usage_seconds
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
mem_usage_seconds
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
object_status
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
parseSize
(size)ΒΆ - Description
Parses string as numeric, suffix and converts to bytes.
-
read_pod_metrics
()ΒΆ - Description
Uses metrics_server to get cadvisor data.
-
read_pod_usage
()ΒΆ - Description
Converts metrics into dictionary for api usage.
-
splitNumeric
(size)ΒΆ - Description
Parses string into numeric component.
-
status
()ΒΆ - Description
Returns status data of object.
Target Cluster ModelΒΆ
-
class
kubernetes_manager.models.target_cluster.
TargetCluster
(*args, **kwargs)ΒΆ Bases:
django_extensions.db.models.TitleSlugDescriptionModel
- Type
model
- Description
Holds data related to a cluster context.
- Inherits
django_extensions.db.models.TitleSlugDescriptionModel
- Fields
api_endpoint, telemetry_endpoint, telemetry_source, config
- Parameters
id (AutoField) β Id
title (CharField) β Title
description (TextField) β Description
slug (AutoSlugField) β Slug
api_endpoint (URLField) β Cluster Endpoint URL
telemetry_endpoint (URLField) β Telemetry Endpoint URL
telemetry_source (CharField) β Telemetry source
config (JSONField) β Equivalent to .kube/config but all JSON
-
exception
DoesNotExist
ΒΆ Bases:
django.core.exceptions.ObjectDoesNotExist
-
exception
MultipleObjectsReturned
ΒΆ Bases:
django.core.exceptions.MultipleObjectsReturned
-
classmethod
add
(kubeconfig)ΒΆ Class method to a new TargetCluster
- Args:
kubeconfig (str) - string contents of kubeconfig file
- Returns:
list(TargetCluster)
-
api_endpoint
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
config
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
get_telemetry_source_display
(*, field=<django.db.models.fields.CharField: telemetry_source>)ΒΆ
-
id
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
kubernetesconfigmap_set
ΒΆ Accessor to the related objects manager on the reverse side of a many-to-one relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Parent.children
is aReverseManyToOneDescriptor
instance.Most of the implementation is delegated to a dynamically defined manager class built by
create_forward_many_to_many_manager()
defined below.
-
kubernetescontainer_set
ΒΆ Accessor to the related objects manager on the reverse side of a many-to-one relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Parent.children
is aReverseManyToOneDescriptor
instance.Most of the implementation is delegated to a dynamically defined manager class built by
create_forward_many_to_many_manager()
defined below.
-
kubernetesdeployment_set
ΒΆ Accessor to the related objects manager on the reverse side of a many-to-one relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Parent.children
is aReverseManyToOneDescriptor
instance.Most of the implementation is delegated to a dynamically defined manager class built by
create_forward_many_to_many_manager()
defined below.
-
kubernetesingress_set
ΒΆ Accessor to the related objects manager on the reverse side of a many-to-one relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Parent.children
is aReverseManyToOneDescriptor
instance.Most of the implementation is delegated to a dynamically defined manager class built by
create_forward_many_to_many_manager()
defined below.
-
kubernetesjob_set
ΒΆ Accessor to the related objects manager on the reverse side of a many-to-one relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Parent.children
is aReverseManyToOneDescriptor
instance.Most of the implementation is delegated to a dynamically defined manager class built by
create_forward_many_to_many_manager()
defined below.
-
kubernetesnamespace_set
ΒΆ Accessor to the related objects manager on the reverse side of a many-to-one relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Parent.children
is aReverseManyToOneDescriptor
instance.Most of the implementation is delegated to a dynamically defined manager class built by
create_forward_many_to_many_manager()
defined below.
-
kubernetespodtemplate_set
ΒΆ Accessor to the related objects manager on the reverse side of a many-to-one relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Parent.children
is aReverseManyToOneDescriptor
instance.Most of the implementation is delegated to a dynamically defined manager class built by
create_forward_many_to_many_manager()
defined below.
-
kubernetesservice_set
ΒΆ Accessor to the related objects manager on the reverse side of a many-to-one relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Parent.children
is aReverseManyToOneDescriptor
instance.Most of the implementation is delegated to a dynamically defined manager class built by
create_forward_many_to_many_manager()
defined below.
-
kubernetesvolume_set
ΒΆ Accessor to the related objects manager on the reverse side of a many-to-one relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Parent.children
is aReverseManyToOneDescriptor
instance.Most of the implementation is delegated to a dynamically defined manager class built by
create_forward_many_to_many_manager()
defined below.
-
kubernetesvolumemount_set
ΒΆ Accessor to the related objects manager on the reverse side of a many-to-one relation.
In the example:
class Child(Model): parent = ForeignKey(Parent, related_name='children')
Parent.children
is aReverseManyToOneDescriptor
instance.Most of the implementation is delegated to a dynamically defined manager class built by
create_forward_many_to_many_manager()
defined below.
-
objects
= <django.db.models.manager.Manager object>ΒΆ
-
telemetry_endpoint
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
-
telemetry_source
ΒΆ A wrapper for a deferred-loading field. When the value is read from this object the first time, the query is executed.
SerializersΒΆ
API SerializersΒΆ
-
class
kubernetes_manager.serializers.base.
KubernetesBaseSerializer
(*args: Any, **kwargs: Any)ΒΆ Bases:
rest_framework.serializers.HyperlinkedModelSerializer
-
class
kubernetes_manager.serializers.base.
KubernetesConfigMapSerializer
(*args: Any, **kwargs: Any)ΒΆ Bases:
kubernetes_manager.serializers.base.KubernetesMetadataObjBaseSerializer
-
class
kubernetes_manager.serializers.base.
KubernetesContainerSerializer
(*args: Any, **kwargs: Any)ΒΆ Bases:
kubernetes_manager.serializers.base.KubernetesBaseSerializer
-
class
kubernetes_manager.serializers.base.
KubernetesDeploymentSerializer
(*args: Any, **kwargs: Any)ΒΆ Bases:
kubernetes_manager.serializers.base.KubernetesNetworkingBaseSerializer
-
class
Meta
ΒΆ Bases:
object
-
fields
= ['title', 'description', 'cluster', 'config', 'labels', 'annotations', 'api_version', 'kind', 'port', 'namespace', 'kuid', 'selector', 'replicas', 'pod_template']ΒΆ
-
model
ΒΆ alias of
kubernetes_manager.models.kube.KubernetesDeployment
-
-
class
-
class
kubernetes_manager.serializers.base.
KubernetesIngressSerializer
(*args: Any, **kwargs: Any)ΒΆ Bases:
kubernetes_manager.serializers.base.KubernetesNetworkingBaseSerializer
-
class
kubernetes_manager.serializers.base.
KubernetesJobSerializer
(*args: Any, **kwargs: Any)ΒΆ Bases:
kubernetes_manager.serializers.base.KubernetesNetworkingBaseSerializer
-
class
kubernetes_manager.serializers.base.
KubernetesMetadataObjBaseSerializer
(*args: Any, **kwargs: Any)ΒΆ Bases:
kubernetes_manager.serializers.base.KubernetesBaseSerializer
-
class
Meta
ΒΆ Bases:
object
-
abstract
= TrueΒΆ
-
fields
= ['title', 'description', 'cluster', 'config', 'labels', 'annotations']ΒΆ
-
model
ΒΆ alias of
kubernetes_manager.models.base.KubernetesMetadataObjBase
-
-
class
-
class
kubernetes_manager.serializers.base.
KubernetesNamespaceSerializer
(*args: Any, **kwargs: Any)ΒΆ Bases:
kubernetes_manager.serializers.base.KubernetesMetadataObjBaseSerializer
-
class
kubernetes_manager.serializers.base.
KubernetesNetworkingBaseSerializer
(*args: Any, **kwargs: Any)ΒΆ Bases:
kubernetes_manager.serializers.base.KubernetesMetadataObjBaseSerializer
-
class
Meta
ΒΆ Bases:
object
-
abstract
= TrueΒΆ
-
fields
= ['title', 'description', 'cluster', 'config', 'labels', 'annotations', 'api_version', 'kind', 'port', 'namespace', 'kuid']ΒΆ
-
model
ΒΆ alias of
kubernetes_manager.models.base.KubernetesNetworkingBase
-
-
class
-
class
kubernetes_manager.serializers.base.
KubernetesPodTemplateSerializer
(*args: Any, **kwargs: Any)ΒΆ Bases:
kubernetes_manager.serializers.base.KubernetesMetadataObjBaseSerializer
-
class
Meta
ΒΆ Bases:
object
-
fields
= ['title', 'description', 'cluster', 'config', 'labels', 'annotations', 'volumes', 'containers', 'restart_policy']ΒΆ
-
model
ΒΆ alias of
kubernetes_manager.models.kube.KubernetesPodTemplate
-
-
class
-
class
kubernetes_manager.serializers.base.
KubernetesServiceSerializer
(*args: Any, **kwargs: Any)ΒΆ Bases:
kubernetes_manager.serializers.base.KubernetesNetworkingBaseSerializer
-
class
kubernetes_manager.serializers.base.
KubernetesVolumeMountSerializer
(*args: Any, **kwargs: Any)ΒΆ Bases:
kubernetes_manager.serializers.base.KubernetesBaseSerializer
-
class
Meta
ΒΆ Bases:
object
-
fields
= ['title', 'description', 'cluster', 'config', 'mount_path', 'sub_path']ΒΆ
-
model
ΒΆ alias of
kubernetes_manager.models.kube.KubernetesVolumeMount
-
-
class
-
class
kubernetes_manager.serializers.base.
KubernetesVolumeSerializer
(*args: Any, **kwargs: Any)ΒΆ Bases:
kubernetes_manager.serializers.base.KubernetesBaseSerializer
-
class
kubernetes_manager.serializers.base.
TargetClusterSerializer
(*args: Any, **kwargs: Any)ΒΆ Bases:
rest_framework.serializers.HyperlinkedModelSerializer
-
class
Meta
ΒΆ Bases:
object
-
fields
= ['title', 'api_endpoint', 'telemetry_endpoint', 'config']ΒΆ
-
model
ΒΆ alias of
kubernetes_manager.models.target_cluster.TargetCluster
-
-
class
ViewsΒΆ
API ViewsΒΆ
-
class
kubernetes_manager.views.model_views.
KubernetesConfigMapViewSet
(*args: Any, **kwargs: Any)ΒΆ Bases:
rest_framework.viewsets.ModelViewSet
API endpoint that allows configmaps to be edited or deleted
-
deploy
(request, *args, **kwargs)ΒΆ Action to deploy the ConfigMap resource to target cluster.
-
permission_classes
= [rest_framework.permissions.IsAuthenticated]ΒΆ
-
queryset
ΒΆ
-
remove
(request, *args, **kwargs)ΒΆ Action to delete the kubernetes ConfigMap from the cluster.
-
serializer_class
ΒΆ alias of
kubernetes_manager.serializers.base.KubernetesConfigMapSerializer
-
-
class
kubernetes_manager.views.model_views.
KubernetesContainerViewSet
(*args: Any, **kwargs: Any)ΒΆ Bases:
rest_framework.viewsets.ModelViewSet
API endpoint that allows containers to be edited or deleted.
-
permission_classes
= [rest_framework.permissions.IsAuthenticated]ΒΆ
-
queryset
ΒΆ
-
serializer_class
ΒΆ alias of
kubernetes_manager.serializers.base.KubernetesContainerSerializer
-
-
class
kubernetes_manager.views.model_views.
KubernetesDeploymentViewSet
(*args: Any, **kwargs: Any)ΒΆ Bases:
rest_framework.viewsets.ModelViewSet
API endpoint that allows deployments to be edited or deleted.
-
deploy
(request, *args, **kwargs)ΒΆ Action to deploy the kubernetes resource to target cluster.
-
permission_classes
= [rest_framework.permissions.IsAuthenticated]ΒΆ
-
pod_usage
(request, *args, **kwargs)ΒΆ Action to fetch point-in-time cpu and memory usage of pod.
-
queryset
ΒΆ
-
remove
(request, *args, **kwargs)ΒΆ Action to delete the kubernetes resource from the cluster/namespaces
-
serializer_class
ΒΆ alias of
kubernetes_manager.serializers.base.KubernetesDeploymentSerializer
-
-
class
kubernetes_manager.views.model_views.
KubernetesIngressViewSet
(*args: Any, **kwargs: Any)ΒΆ Bases:
rest_framework.viewsets.ModelViewSet
API endpoint that allows ingress to be edited or deleted.
-
deploy
(request, *args, **kwargs)ΒΆ Action to deploy the kubernetes resource to target cluster.
-
permission_classes
= [rest_framework.permissions.IsAuthenticated]ΒΆ
-
queryset
ΒΆ
-
remove
(request, *args, **kwargs)ΒΆ Action to delete the kubernetes resource from the cluster/namespace.
-
serializer_class
ΒΆ alias of
kubernetes_manager.serializers.base.KubernetesIngressSerializer
-
-
class
kubernetes_manager.views.model_views.
KubernetesJobViewSet
(*args: Any, **kwargs: Any)ΒΆ Bases:
rest_framework.viewsets.ModelViewSet
API endpoint that allows jobs to be edited or deleted.
-
deploy
(request, *args, **kwargs)ΒΆ Action to deploy the kubernetes resource to target cluster.
-
permission_classes
= [rest_framework.permissions.IsAuthenticated]ΒΆ
-
pod_usage
(request, *args, **kwargs)ΒΆ Action to fetch point-in-time cpu and memory usage of pod.
-
queryset
ΒΆ
-
remove
(request, *args, **kwargs)ΒΆ Action to delete the kubernetes resource from the target cluster/ns.
-
serializer_class
ΒΆ alias of
kubernetes_manager.serializers.base.KubernetesJobSerializer
-
-
class
kubernetes_manager.views.model_views.
KubernetesNamespaceViewSet
(*args: Any, **kwargs: Any)ΒΆ Bases:
rest_framework.viewsets.ModelViewSet
API endpoint that allows namespaces to be created or deleted
-
deploy
(request, *args, **kwargs)ΒΆ Action to deploy the namespace resource to target cluster.
-
permission_classes
= [rest_framework.permissions.IsAuthenticated]ΒΆ
-
queryset
ΒΆ
-
remove
(request, *args, **kwargs)ΒΆ Action to delete the kubernetes namespace from the cluster.
-
serializer_class
ΒΆ alias of
kubernetes_manager.serializers.base.KubernetesNamespaceSerializer
-
-
class
kubernetes_manager.views.model_views.
KubernetesPodTemplateViewSet
(*args: Any, **kwargs: Any)ΒΆ Bases:
rest_framework.viewsets.ModelViewSet
API endpoint that allows pod templates to be edited or deleted.
-
permission_classes
= [rest_framework.permissions.IsAuthenticated]ΒΆ
-
queryset
ΒΆ
-
serializer_class
ΒΆ alias of
kubernetes_manager.serializers.base.KubernetesPodTemplateSerializer
-
-
class
kubernetes_manager.views.model_views.
KubernetesServiceViewSet
(*args: Any, **kwargs: Any)ΒΆ Bases:
rest_framework.viewsets.ModelViewSet
API endpoint that allows services to be edited or deleted.
-
deploy
(request, *args, **kwargs)ΒΆ Action to deploy the kubernetes resource to target cluster.
-
permission_classes
= [rest_framework.permissions.IsAuthenticated]ΒΆ
-
queryset
ΒΆ
-
remove
(request, *args, **kwargs)ΒΆ Action to delete the kubernetes resource from the cluster/namespace.
-
serializer_class
ΒΆ alias of
kubernetes_manager.serializers.base.KubernetesServiceSerializer
-
-
class
kubernetes_manager.views.model_views.
KubernetesVolumeMountViewSet
(*args: Any, **kwargs: Any)ΒΆ Bases:
rest_framework.viewsets.ModelViewSet
API endpoint that allows volumes to be edited or deleted.
-
permission_classes
= [rest_framework.permissions.IsAuthenticated]ΒΆ
-
queryset
ΒΆ
-
serializer_class
ΒΆ alias of
kubernetes_manager.serializers.base.KubernetesVolumeMountSerializer
-
-
class
kubernetes_manager.views.model_views.
KubernetesVolumeViewSet
(*args: Any, **kwargs: Any)ΒΆ Bases:
rest_framework.viewsets.ModelViewSet
API endpoint that allows volumes to be edited or deleted.
-
permission_classes
= [rest_framework.permissions.IsAuthenticated]ΒΆ
-
queryset
ΒΆ
-
serializer_class
ΒΆ alias of
kubernetes_manager.serializers.base.KubernetesVolumeSerializer
-
-
class
kubernetes_manager.views.model_views.
TargetClusterViewSet
(*args: Any, **kwargs: Any)ΒΆ Bases:
rest_framework.viewsets.ModelViewSet
API endpoint that allows cluster configs to be edited or deleted
-
permission_classes
= [rest_framework.permissions.IsAuthenticated]ΒΆ
-
queryset
ΒΆ
-
serializer_class
ΒΆ alias of
kubernetes_manager.serializers.base.TargetClusterSerializer
-
UtilsΒΆ
Kubernetes UtilsΒΆ
-
kubernetes_manager.utils.
coalesce_dicts
(target=<class 'dict'>, source=<class 'dict'>)ΒΆ
-
kubernetes_manager.utils.
find_namespaced_pods
(namespace, job_name, api_client)ΒΆ find pod by namespace and job name
- Args:
namespace (str) - job_name (str) - api_client (CoreV1Api) -
- Returns:
str - Name of the pod if found
-
kubernetes_manager.utils.
generate_kubeconfig
(context, cluster, user, default_name='k8s-job-runner')ΒΆ Format helper for generating individual cluster kubeconfigs
- Args:
context (dict) - cluster (dict) - user (dict) -
- Returns:
dict -
-
kubernetes_manager.utils.
get_command_output
(cmd)ΒΆ retrieve command output for a given command provided
-
kubernetes_manager.utils.
get_dict_hash
(data)ΒΆ
-
kubernetes_manager.utils.
run_command
(cmd, log_method=<bound method Logger.info of <Logger kubernetes_manager.utils (WARNING)>>)ΒΆ Subprocess wrapper for capturing output of processes to logs
-
kubernetes_manager.utils.
split_kubeconfig
(kubeconfig)ΒΆ Helper method to split a kubeconfig into separate, per-cluster configurations
- Args:
kubeconfig (dict or str) -
- Returns:
list(dict)
API SpecΒΆ
clustersΒΆ
-
GET
/clusters/
ΒΆ API endpoint that allows cluster configs to be edited or deleted
- Status Codes
200 OK β
- Response JSON Object
[].api_endpoint (string) β Cluster Endpoint URL (required)
[].telemetry_endpoint (string) β Telemetry Endpoint URL (required)
[].title (string) β (required)
-
POST
/clusters/
ΒΆ API endpoint that allows cluster configs to be edited or deleted
- Request JSON Object
api_endpoint (string) β Cluster Endpoint URL (required)
telemetry_endpoint (string) β Telemetry Endpoint URL (required)
title (string) β (required)
- Status Codes
201 Created β
- Response JSON Object
api_endpoint (string) β Cluster Endpoint URL (required)
telemetry_endpoint (string) β Telemetry Endpoint URL (required)
title (string) β (required)
-
GET
/clusters/{id}/
ΒΆ API endpoint that allows cluster configs to be edited or deleted
- Parameters
id (integer) β A unique integer value identifying this target cluster.
- Status Codes
200 OK β
- Response JSON Object
api_endpoint (string) β Cluster Endpoint URL (required)
telemetry_endpoint (string) β Telemetry Endpoint URL (required)
title (string) β (required)
-
PUT
/clusters/{id}/
ΒΆ API endpoint that allows cluster configs to be edited or deleted
- Parameters
id (integer) β A unique integer value identifying this target cluster.
- Request JSON Object
api_endpoint (string) β Cluster Endpoint URL (required)
telemetry_endpoint (string) β Telemetry Endpoint URL (required)
title (string) β (required)
- Status Codes
200 OK β
- Response JSON Object
api_endpoint (string) β Cluster Endpoint URL (required)
telemetry_endpoint (string) β Telemetry Endpoint URL (required)
title (string) β (required)
-
PATCH
/clusters/{id}/
ΒΆ API endpoint that allows cluster configs to be edited or deleted
- Parameters
id (integer) β A unique integer value identifying this target cluster.
- Request JSON Object
api_endpoint (string) β Cluster Endpoint URL (required)
telemetry_endpoint (string) β Telemetry Endpoint URL (required)
title (string) β (required)
- Status Codes
200 OK β
- Response JSON Object
api_endpoint (string) β Cluster Endpoint URL (required)
telemetry_endpoint (string) β Telemetry Endpoint URL (required)
title (string) β (required)
-
DELETE
/clusters/{id}/
ΒΆ API endpoint that allows cluster configs to be edited or deleted
- Parameters
id (integer) β A unique integer value identifying this target cluster.
- Status Codes
204 No Content β
configmapsΒΆ
-
GET
/configmaps/
ΒΆ API endpoint that allows configmaps to be edited or deleted
- Status Codes
200 OK β
- Response JSON Object
[].cluster (string) β ForeignKey to TargetCluster object.
[].description (string) β
[].kind (string) β
[].title (string) β (required)
-
POST
/configmaps/
ΒΆ API endpoint that allows configmaps to be edited or deleted
- Request JSON Object
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
kind (string) β
title (string) β (required)
- Status Codes
201 Created β
- Response JSON Object
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
kind (string) β
title (string) β (required)
-
GET
/configmaps/{id}/
ΒΆ API endpoint that allows configmaps to be edited or deleted
- Parameters
id (string) β UUID Auto field.
- Status Codes
200 OK β
- Response JSON Object
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
kind (string) β
title (string) β (required)
-
PUT
/configmaps/{id}/
ΒΆ API endpoint that allows configmaps to be edited or deleted
- Parameters
id (string) β UUID Auto field.
- Request JSON Object
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
kind (string) β
title (string) β (required)
- Status Codes
200 OK β
- Response JSON Object
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
kind (string) β
title (string) β (required)
-
PATCH
/configmaps/{id}/
ΒΆ API endpoint that allows configmaps to be edited or deleted
- Parameters
id (string) β UUID Auto field.
- Request JSON Object
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
kind (string) β
title (string) β (required)
- Status Codes
200 OK β
- Response JSON Object
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
kind (string) β
title (string) β (required)
-
DELETE
/configmaps/{id}/
ΒΆ API endpoint that allows configmaps to be edited or deleted
- Parameters
id (string) β UUID Auto field.
- Status Codes
204 No Content β
-
GET
/configmaps/{id}/deploy/
ΒΆ Action to deploy the ConfigMap resource to target cluster.
- Parameters
id (string) β UUID Auto field.
- Status Codes
200 OK β
- Response JSON Object
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
kind (string) β
title (string) β (required)
-
GET
/configmaps/{id}/remove/
ΒΆ Action to delete the kubernetes ConfigMap from the cluster.
- Parameters
id (string) β UUID Auto field.
- Status Codes
200 OK β
- Response JSON Object
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
kind (string) β
title (string) β (required)
containersΒΆ
-
GET
/containers/
ΒΆ API endpoint that allows containers to be edited or deleted.
- Status Codes
200 OK β
- Response JSON Object
[].args (string) β Comma separated args to run with command when instantiating container.
[].cluster (string) β ForeignKey to TargetCluster object.
[].command (string) β Command to run when start container
[].description (string) β
[].image_name (string) β Properly qualified image name.
[].image_pull_policy (string) β
[].image_tag (string) β Tag name for the image to be used for this job
[].port (integer) β
[].title (string) β (required)
[].volume_mount (string) β
-
POST
/containers/
ΒΆ API endpoint that allows containers to be edited or deleted.
- Request JSON Object
args (string) β Comma separated args to run with command when instantiating container.
cluster (string) β ForeignKey to TargetCluster object.
command (string) β Command to run when start container
description (string) β
image_name (string) β Properly qualified image name.
image_pull_policy (string) β
image_tag (string) β Tag name for the image to be used for this job
port (integer) β
title (string) β (required)
volume_mount (string) β
- Status Codes
201 Created β
- Response JSON Object
args (string) β Comma separated args to run with command when instantiating container.
cluster (string) β ForeignKey to TargetCluster object.
command (string) β Command to run when start container
description (string) β
image_name (string) β Properly qualified image name.
image_pull_policy (string) β
image_tag (string) β Tag name for the image to be used for this job
port (integer) β
title (string) β (required)
volume_mount (string) β
-
GET
/containers/{id}/
ΒΆ API endpoint that allows containers to be edited or deleted.
- Parameters
id (string) β UUID Auto field.
- Status Codes
200 OK β
- Response JSON Object
args (string) β Comma separated args to run with command when instantiating container.
cluster (string) β ForeignKey to TargetCluster object.
command (string) β Command to run when start container
description (string) β
image_name (string) β Properly qualified image name.
image_pull_policy (string) β
image_tag (string) β Tag name for the image to be used for this job
port (integer) β
title (string) β (required)
volume_mount (string) β
-
PUT
/containers/{id}/
ΒΆ API endpoint that allows containers to be edited or deleted.
- Parameters
id (string) β UUID Auto field.
- Request JSON Object
args (string) β Comma separated args to run with command when instantiating container.
cluster (string) β ForeignKey to TargetCluster object.
command (string) β Command to run when start container
description (string) β
image_name (string) β Properly qualified image name.
image_pull_policy (string) β
image_tag (string) β Tag name for the image to be used for this job
port (integer) β
title (string) β (required)
volume_mount (string) β
- Status Codes
200 OK β
- Response JSON Object
args (string) β Comma separated args to run with command when instantiating container.
cluster (string) β ForeignKey to TargetCluster object.
command (string) β Command to run when start container
description (string) β
image_name (string) β Properly qualified image name.
image_pull_policy (string) β
image_tag (string) β Tag name for the image to be used for this job
port (integer) β
title (string) β (required)
volume_mount (string) β
-
PATCH
/containers/{id}/
ΒΆ API endpoint that allows containers to be edited or deleted.
- Parameters
id (string) β UUID Auto field.
- Request JSON Object
args (string) β Comma separated args to run with command when instantiating container.
cluster (string) β ForeignKey to TargetCluster object.
command (string) β Command to run when start container
description (string) β
image_name (string) β Properly qualified image name.
image_pull_policy (string) β
image_tag (string) β Tag name for the image to be used for this job
port (integer) β
title (string) β (required)
volume_mount (string) β
- Status Codes
200 OK β
- Response JSON Object
args (string) β Comma separated args to run with command when instantiating container.
cluster (string) β ForeignKey to TargetCluster object.
command (string) β Command to run when start container
description (string) β
image_name (string) β Properly qualified image name.
image_pull_policy (string) β
image_tag (string) β Tag name for the image to be used for this job
port (integer) β
title (string) β (required)
volume_mount (string) β
-
DELETE
/containers/{id}/
ΒΆ API endpoint that allows containers to be edited or deleted.
- Parameters
id (string) β UUID Auto field.
- Status Codes
204 No Content β
deploymentsΒΆ
-
GET
/deployments/
ΒΆ API endpoint that allows deployments to be edited or deleted.
- Status Codes
200 OK β
- Response JSON Object
[].api_version (string) β API version used to deploy child object.
[].cluster (string) β ForeignKey to TargetCluster object.
[].description (string) β
[].kind (string) β String representation of Kubernetes object kind (required)
[].kuid (string) β Objectβs UID in the cluster
[].namespace (string) β Live namespace the object is associated with. (required)
[].pod_template (string) β (required)
[].port (integer) β Port object will expose
[].replicas (integer) β
[].title (string) β (required)
-
POST
/deployments/
ΒΆ API endpoint that allows deployments to be edited or deleted.
- Request JSON Object
api_version (string) β API version used to deploy child object.
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
kind (string) β String representation of Kubernetes object kind (required)
kuid (string) β Objectβs UID in the cluster
namespace (string) β Live namespace the object is associated with. (required)
pod_template (string) β (required)
port (integer) β Port object will expose
replicas (integer) β
title (string) β (required)
- Status Codes
201 Created β
- Response JSON Object
api_version (string) β API version used to deploy child object.
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
kind (string) β String representation of Kubernetes object kind (required)
kuid (string) β Objectβs UID in the cluster
namespace (string) β Live namespace the object is associated with. (required)
pod_template (string) β (required)
port (integer) β Port object will expose
replicas (integer) β
title (string) β (required)
-
GET
/deployments/{id}/
ΒΆ API endpoint that allows deployments to be edited or deleted.
- Parameters
id (string) β UUID Auto field.
- Status Codes
200 OK β
- Response JSON Object
api_version (string) β API version used to deploy child object.
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
kind (string) β String representation of Kubernetes object kind (required)
kuid (string) β Objectβs UID in the cluster
namespace (string) β Live namespace the object is associated with. (required)
pod_template (string) β (required)
port (integer) β Port object will expose
replicas (integer) β
title (string) β (required)
-
PUT
/deployments/{id}/
ΒΆ API endpoint that allows deployments to be edited or deleted.
- Parameters
id (string) β UUID Auto field.
- Request JSON Object
api_version (string) β API version used to deploy child object.
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
kind (string) β String representation of Kubernetes object kind (required)
kuid (string) β Objectβs UID in the cluster
namespace (string) β Live namespace the object is associated with. (required)
pod_template (string) β (required)
port (integer) β Port object will expose
replicas (integer) β
title (string) β (required)
- Status Codes
200 OK β
- Response JSON Object
api_version (string) β API version used to deploy child object.
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
kind (string) β String representation of Kubernetes object kind (required)
kuid (string) β Objectβs UID in the cluster
namespace (string) β Live namespace the object is associated with. (required)
pod_template (string) β (required)
port (integer) β Port object will expose
replicas (integer) β
title (string) β (required)
-
PATCH
/deployments/{id}/
ΒΆ API endpoint that allows deployments to be edited or deleted.
- Parameters
id (string) β UUID Auto field.
- Request JSON Object
api_version (string) β API version used to deploy child object.
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
kind (string) β String representation of Kubernetes object kind (required)
kuid (string) β Objectβs UID in the cluster
namespace (string) β Live namespace the object is associated with. (required)
pod_template (string) β (required)
port (integer) β Port object will expose
replicas (integer) β
title (string) β (required)
- Status Codes
200 OK β
- Response JSON Object
api_version (string) β API version used to deploy child object.
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
kind (string) β String representation of Kubernetes object kind (required)
kuid (string) β Objectβs UID in the cluster
namespace (string) β Live namespace the object is associated with. (required)
pod_template (string) β (required)
port (integer) β Port object will expose
replicas (integer) β
title (string) β (required)
-
DELETE
/deployments/{id}/
ΒΆ API endpoint that allows deployments to be edited or deleted.
- Parameters
id (string) β UUID Auto field.
- Status Codes
204 No Content β
-
GET
/deployments/{id}/deploy/
ΒΆ Action to deploy the kubernetes resource to target cluster.
- Parameters
id (string) β UUID Auto field.
- Status Codes
200 OK β
- Response JSON Object
api_version (string) β API version used to deploy child object.
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
kind (string) β String representation of Kubernetes object kind (required)
kuid (string) β Objectβs UID in the cluster
namespace (string) β Live namespace the object is associated with. (required)
pod_template (string) β (required)
port (integer) β Port object will expose
replicas (integer) β
title (string) β (required)
-
GET
/deployments/{id}/pod_usage/
ΒΆ Action to fetch point-in-time cpu and memory usage of pod.
- Parameters
id (string) β UUID Auto field.
- Status Codes
200 OK β
- Response JSON Object
api_version (string) β API version used to deploy child object.
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
kind (string) β String representation of Kubernetes object kind (required)
kuid (string) β Objectβs UID in the cluster
namespace (string) β Live namespace the object is associated with. (required)
pod_template (string) β (required)
port (integer) β Port object will expose
replicas (integer) β
title (string) β (required)
-
GET
/deployments/{id}/remove/
ΒΆ Action to delete the kubernetes resource from the cluster/namespaces
- Parameters
id (string) β UUID Auto field.
- Status Codes
200 OK β
- Response JSON Object
api_version (string) β API version used to deploy child object.
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
kind (string) β String representation of Kubernetes object kind (required)
kuid (string) β Objectβs UID in the cluster
namespace (string) β Live namespace the object is associated with. (required)
pod_template (string) β (required)
port (integer) β Port object will expose
replicas (integer) β
title (string) β (required)
ingressesΒΆ
-
GET
/ingresses/
ΒΆ API endpoint that allows ingress to be edited or deleted.
- Status Codes
200 OK β
- Response JSON Object
[].api_version (string) β API version used to deploy child object.
[].cluster (string) β ForeignKey to TargetCluster object.
[].description (string) β
[].hostname (string) β
[].kind (string) β String representation of Kubernetes object kind (required)
[].kuid (string) β Objectβs UID in the cluster
[].namespace (string) β Live namespace the object is associated with. (required)
[].path (string) β
[].port (integer) β Port object will expose
[].target_service (string) β (required)
[].title (string) β (required)
-
POST
/ingresses/
ΒΆ API endpoint that allows ingress to be edited or deleted.
- Request JSON Object
api_version (string) β API version used to deploy child object.
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
hostname (string) β
kind (string) β String representation of Kubernetes object kind (required)
kuid (string) β Objectβs UID in the cluster
namespace (string) β Live namespace the object is associated with. (required)
path (string) β
port (integer) β Port object will expose
target_service (string) β (required)
title (string) β (required)
- Status Codes
201 Created β
- Response JSON Object
api_version (string) β API version used to deploy child object.
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
hostname (string) β
kind (string) β String representation of Kubernetes object kind (required)
kuid (string) β Objectβs UID in the cluster
namespace (string) β Live namespace the object is associated with. (required)
path (string) β
port (integer) β Port object will expose
target_service (string) β (required)
title (string) β (required)
-
GET
/ingresses/{id}/
ΒΆ API endpoint that allows ingress to be edited or deleted.
- Parameters
id (string) β UUID Auto field.
- Status Codes
200 OK β
- Response JSON Object
api_version (string) β API version used to deploy child object.
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
hostname (string) β
kind (string) β String representation of Kubernetes object kind (required)
kuid (string) β Objectβs UID in the cluster
namespace (string) β Live namespace the object is associated with. (required)
path (string) β
port (integer) β Port object will expose
target_service (string) β (required)
title (string) β (required)
-
PUT
/ingresses/{id}/
ΒΆ API endpoint that allows ingress to be edited or deleted.
- Parameters
id (string) β UUID Auto field.
- Request JSON Object
api_version (string) β API version used to deploy child object.
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
hostname (string) β
kind (string) β String representation of Kubernetes object kind (required)
kuid (string) β Objectβs UID in the cluster
namespace (string) β Live namespace the object is associated with. (required)
path (string) β
port (integer) β Port object will expose
target_service (string) β (required)
title (string) β (required)
- Status Codes
200 OK β
- Response JSON Object
api_version (string) β API version used to deploy child object.
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
hostname (string) β
kind (string) β String representation of Kubernetes object kind (required)
kuid (string) β Objectβs UID in the cluster
namespace (string) β Live namespace the object is associated with. (required)
path (string) β
port (integer) β Port object will expose
target_service (string) β (required)
title (string) β (required)
-
PATCH
/ingresses/{id}/
ΒΆ API endpoint that allows ingress to be edited or deleted.
- Parameters
id (string) β UUID Auto field.
- Request JSON Object
api_version (string) β API version used to deploy child object.
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
hostname (string) β
kind (string) β String representation of Kubernetes object kind (required)
kuid (string) β Objectβs UID in the cluster
namespace (string) β Live namespace the object is associated with. (required)
path (string) β
port (integer) β Port object will expose
target_service (string) β (required)
title (string) β (required)
- Status Codes
200 OK β
- Response JSON Object
api_version (string) β API version used to deploy child object.
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
hostname (string) β
kind (string) β String representation of Kubernetes object kind (required)
kuid (string) β Objectβs UID in the cluster
namespace (string) β Live namespace the object is associated with. (required)
path (string) β
port (integer) β Port object will expose
target_service (string) β (required)
title (string) β (required)
-
DELETE
/ingresses/{id}/
ΒΆ API endpoint that allows ingress to be edited or deleted.
- Parameters
id (string) β UUID Auto field.
- Status Codes
204 No Content β
-
GET
/ingresses/{id}/deploy/
ΒΆ Action to deploy the kubernetes resource to target cluster.
- Parameters
id (string) β UUID Auto field.
- Status Codes
200 OK β
- Response JSON Object
api_version (string) β API version used to deploy child object.
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
hostname (string) β
kind (string) β String representation of Kubernetes object kind (required)
kuid (string) β Objectβs UID in the cluster
namespace (string) β Live namespace the object is associated with. (required)
path (string) β
port (integer) β Port object will expose
target_service (string) β (required)
title (string) β (required)
-
GET
/ingresses/{id}/remove/
ΒΆ Action to delete the kubernetes resource from the cluster/namespace.
- Parameters
id (string) β UUID Auto field.
- Status Codes
200 OK β
- Response JSON Object
api_version (string) β API version used to deploy child object.
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
hostname (string) β
kind (string) β String representation of Kubernetes object kind (required)
kuid (string) β Objectβs UID in the cluster
namespace (string) β Live namespace the object is associated with. (required)
path (string) β
port (integer) β Port object will expose
target_service (string) β (required)
title (string) β (required)
jobsΒΆ
-
GET
/jobs/
ΒΆ API endpoint that allows jobs to be edited or deleted.
- Status Codes
200 OK β
- Response JSON Object
[].api_version (string) β API version used to deploy child object.
[].backoff_limit (integer) β
[].cluster (string) β ForeignKey to TargetCluster object.
[].description (string) β
[].kind (string) β String representation of Kubernetes object kind (required)
[].kuid (string) β Objectβs UID in the cluster
[].namespace (string) β Live namespace the object is associated with. (required)
[].pod_template (string) β (required)
[].port (integer) β Port object will expose
[].title (string) β (required)
-
POST
/jobs/
ΒΆ API endpoint that allows jobs to be edited or deleted.
- Request JSON Object
api_version (string) β API version used to deploy child object.
backoff_limit (integer) β
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
kind (string) β String representation of Kubernetes object kind (required)
kuid (string) β Objectβs UID in the cluster
namespace (string) β Live namespace the object is associated with. (required)
pod_template (string) β (required)
port (integer) β Port object will expose
title (string) β (required)
- Status Codes
201 Created β
- Response JSON Object
api_version (string) β API version used to deploy child object.
backoff_limit (integer) β
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
kind (string) β String representation of Kubernetes object kind (required)
kuid (string) β Objectβs UID in the cluster
namespace (string) β Live namespace the object is associated with. (required)
pod_template (string) β (required)
port (integer) β Port object will expose
title (string) β (required)
-
GET
/jobs/{id}/
ΒΆ API endpoint that allows jobs to be edited or deleted.
- Parameters
id (string) β UUID Auto field.
- Status Codes
200 OK β
- Response JSON Object
api_version (string) β API version used to deploy child object.
backoff_limit (integer) β
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
kind (string) β String representation of Kubernetes object kind (required)
kuid (string) β Objectβs UID in the cluster
namespace (string) β Live namespace the object is associated with. (required)
pod_template (string) β (required)
port (integer) β Port object will expose
title (string) β (required)
-
PUT
/jobs/{id}/
ΒΆ API endpoint that allows jobs to be edited or deleted.
- Parameters
id (string) β UUID Auto field.
- Request JSON Object
api_version (string) β API version used to deploy child object.
backoff_limit (integer) β
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
kind (string) β String representation of Kubernetes object kind (required)
kuid (string) β Objectβs UID in the cluster
namespace (string) β Live namespace the object is associated with. (required)
pod_template (string) β (required)
port (integer) β Port object will expose
title (string) β (required)
- Status Codes
200 OK β
- Response JSON Object
api_version (string) β API version used to deploy child object.
backoff_limit (integer) β
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
kind (string) β String representation of Kubernetes object kind (required)
kuid (string) β Objectβs UID in the cluster
namespace (string) β Live namespace the object is associated with. (required)
pod_template (string) β (required)
port (integer) β Port object will expose
title (string) β (required)
-
PATCH
/jobs/{id}/
ΒΆ API endpoint that allows jobs to be edited or deleted.
- Parameters
id (string) β UUID Auto field.
- Request JSON Object
api_version (string) β API version used to deploy child object.
backoff_limit (integer) β
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
kind (string) β String representation of Kubernetes object kind (required)
kuid (string) β Objectβs UID in the cluster
namespace (string) β Live namespace the object is associated with. (required)
pod_template (string) β (required)
port (integer) β Port object will expose
title (string) β (required)
- Status Codes
200 OK β
- Response JSON Object
api_version (string) β API version used to deploy child object.
backoff_limit (integer) β
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
kind (string) β String representation of Kubernetes object kind (required)
kuid (string) β Objectβs UID in the cluster
namespace (string) β Live namespace the object is associated with. (required)
pod_template (string) β (required)
port (integer) β Port object will expose
title (string) β (required)
-
DELETE
/jobs/{id}/
ΒΆ API endpoint that allows jobs to be edited or deleted.
- Parameters
id (string) β UUID Auto field.
- Status Codes
204 No Content β
-
GET
/jobs/{id}/deploy/
ΒΆ Action to deploy the kubernetes resource to target cluster.
- Parameters
id (string) β UUID Auto field.
- Status Codes
200 OK β
- Response JSON Object
api_version (string) β API version used to deploy child object.
backoff_limit (integer) β
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
kind (string) β String representation of Kubernetes object kind (required)
kuid (string) β Objectβs UID in the cluster
namespace (string) β Live namespace the object is associated with. (required)
pod_template (string) β (required)
port (integer) β Port object will expose
title (string) β (required)
-
GET
/jobs/{id}/pod_usage/
ΒΆ Action to fetch point-in-time cpu and memory usage of pod.
- Parameters
id (string) β UUID Auto field.
- Status Codes
200 OK β
- Response JSON Object
api_version (string) β API version used to deploy child object.
backoff_limit (integer) β
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
kind (string) β String representation of Kubernetes object kind (required)
kuid (string) β Objectβs UID in the cluster
namespace (string) β Live namespace the object is associated with. (required)
pod_template (string) β (required)
port (integer) β Port object will expose
title (string) β (required)
-
GET
/jobs/{id}/remove/
ΒΆ Action to delete the kubernetes resource from the target cluster/ns.
- Parameters
id (string) β UUID Auto field.
- Status Codes
200 OK β
- Response JSON Object
api_version (string) β API version used to deploy child object.
backoff_limit (integer) β
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
kind (string) β String representation of Kubernetes object kind (required)
kuid (string) β Objectβs UID in the cluster
namespace (string) β Live namespace the object is associated with. (required)
pod_template (string) β (required)
port (integer) β Port object will expose
title (string) β (required)
mountsΒΆ
-
GET
/mounts/
ΒΆ API endpoint that allows volumes to be edited or deleted.
- Status Codes
200 OK β
- Response JSON Object
[].cluster (string) β ForeignKey to TargetCluster object.
[].description (string) β
[].mount_path (string) β
[].sub_path (string) β
[].title (string) β (required)
-
POST
/mounts/
ΒΆ API endpoint that allows volumes to be edited or deleted.
- Request JSON Object
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
mount_path (string) β
sub_path (string) β
title (string) β (required)
- Status Codes
201 Created β
- Response JSON Object
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
mount_path (string) β
sub_path (string) β
title (string) β (required)
-
GET
/mounts/{id}/
ΒΆ API endpoint that allows volumes to be edited or deleted.
- Parameters
id (string) β UUID Auto field.
- Status Codes
200 OK β
- Response JSON Object
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
mount_path (string) β
sub_path (string) β
title (string) β (required)
-
PUT
/mounts/{id}/
ΒΆ API endpoint that allows volumes to be edited or deleted.
- Parameters
id (string) β UUID Auto field.
- Request JSON Object
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
mount_path (string) β
sub_path (string) β
title (string) β (required)
- Status Codes
200 OK β
- Response JSON Object
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
mount_path (string) β
sub_path (string) β
title (string) β (required)
-
PATCH
/mounts/{id}/
ΒΆ API endpoint that allows volumes to be edited or deleted.
- Parameters
id (string) β UUID Auto field.
- Request JSON Object
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
mount_path (string) β
sub_path (string) β
title (string) β (required)
- Status Codes
200 OK β
- Response JSON Object
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
mount_path (string) β
sub_path (string) β
title (string) β (required)
-
DELETE
/mounts/{id}/
ΒΆ API endpoint that allows volumes to be edited or deleted.
- Parameters
id (string) β UUID Auto field.
- Status Codes
204 No Content β
namespacesΒΆ
-
GET
/namespaces/
ΒΆ API endpoint that allows namespaces to be created or deleted
- Status Codes
200 OK β
- Response JSON Object
[].api_version (string) β
[].cluster (string) β ForeignKey to TargetCluster object.
[].description (string) β
[].exists (boolean) β
[].kind (string) β
[].title (string) β (required)
-
POST
/namespaces/
ΒΆ API endpoint that allows namespaces to be created or deleted
- Request JSON Object
api_version (string) β
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
exists (boolean) β
kind (string) β
title (string) β (required)
- Status Codes
201 Created β
- Response JSON Object
api_version (string) β
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
exists (boolean) β
kind (string) β
title (string) β (required)
-
GET
/namespaces/{id}/
ΒΆ API endpoint that allows namespaces to be created or deleted
- Parameters
id (string) β UUID Auto field.
- Status Codes
200 OK β
- Response JSON Object
api_version (string) β
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
exists (boolean) β
kind (string) β
title (string) β (required)
-
PUT
/namespaces/{id}/
ΒΆ API endpoint that allows namespaces to be created or deleted
- Parameters
id (string) β UUID Auto field.
- Request JSON Object
api_version (string) β
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
exists (boolean) β
kind (string) β
title (string) β (required)
- Status Codes
200 OK β
- Response JSON Object
api_version (string) β
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
exists (boolean) β
kind (string) β
title (string) β (required)
-
PATCH
/namespaces/{id}/
ΒΆ API endpoint that allows namespaces to be created or deleted
- Parameters
id (string) β UUID Auto field.
- Request JSON Object
api_version (string) β
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
exists (boolean) β
kind (string) β
title (string) β (required)
- Status Codes
200 OK β
- Response JSON Object
api_version (string) β
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
exists (boolean) β
kind (string) β
title (string) β (required)
-
DELETE
/namespaces/{id}/
ΒΆ API endpoint that allows namespaces to be created or deleted
- Parameters
id (string) β UUID Auto field.
- Status Codes
204 No Content β
-
GET
/namespaces/{id}/deploy/
ΒΆ Action to deploy the namespace resource to target cluster.
- Parameters
id (string) β UUID Auto field.
- Status Codes
200 OK β
- Response JSON Object
api_version (string) β
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
exists (boolean) β
kind (string) β
title (string) β (required)
-
GET
/namespaces/{id}/remove/
ΒΆ Action to delete the kubernetes namespace from the cluster.
- Parameters
id (string) β UUID Auto field.
- Status Codes
200 OK β
- Response JSON Object
api_version (string) β
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
exists (boolean) β
kind (string) β
title (string) β (required)
podsΒΆ
-
GET
/pods/
ΒΆ API endpoint that allows pod templates to be edited or deleted.
- Status Codes
200 OK β
- Response JSON Object
[].cluster (string) β ForeignKey to TargetCluster object.
[].description (string) β
[].primary_container (string) β (required)
[].restart_policy (string) β
[].secondary_container (string) β
[].title (string) β (required)
[].volume (string) β
-
POST
/pods/
ΒΆ API endpoint that allows pod templates to be edited or deleted.
- Request JSON Object
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
primary_container (string) β (required)
restart_policy (string) β
secondary_container (string) β
title (string) β (required)
volume (string) β
- Status Codes
201 Created β
- Response JSON Object
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
primary_container (string) β (required)
restart_policy (string) β
secondary_container (string) β
title (string) β (required)
volume (string) β
-
GET
/pods/{id}/
ΒΆ API endpoint that allows pod templates to be edited or deleted.
- Parameters
id (string) β UUID Auto field.
- Status Codes
200 OK β
- Response JSON Object
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
primary_container (string) β (required)
restart_policy (string) β
secondary_container (string) β
title (string) β (required)
volume (string) β
-
PUT
/pods/{id}/
ΒΆ API endpoint that allows pod templates to be edited or deleted.
- Parameters
id (string) β UUID Auto field.
- Request JSON Object
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
primary_container (string) β (required)
restart_policy (string) β
secondary_container (string) β
title (string) β (required)
volume (string) β
- Status Codes
200 OK β
- Response JSON Object
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
primary_container (string) β (required)
restart_policy (string) β
secondary_container (string) β
title (string) β (required)
volume (string) β
-
PATCH
/pods/{id}/
ΒΆ API endpoint that allows pod templates to be edited or deleted.
- Parameters
id (string) β UUID Auto field.
- Request JSON Object
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
primary_container (string) β (required)
restart_policy (string) β
secondary_container (string) β
title (string) β (required)
volume (string) β
- Status Codes
200 OK β
- Response JSON Object
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
primary_container (string) β (required)
restart_policy (string) β
secondary_container (string) β
title (string) β (required)
volume (string) β
-
DELETE
/pods/{id}/
ΒΆ API endpoint that allows pod templates to be edited or deleted.
- Parameters
id (string) β UUID Auto field.
- Status Codes
204 No Content β
servicesΒΆ
-
GET
/services/
ΒΆ API endpoint that allows services to be edited or deleted.
- Status Codes
200 OK β
- Response JSON Object
[].api_version (string) β API version used to deploy child object.
[].cluster (string) β ForeignKey to TargetCluster object.
[].description (string) β
[].kind (string) β String representation of Kubernetes object kind (required)
[].kuid (string) β Objectβs UID in the cluster
[].namespace (string) β Live namespace the object is associated with. (required)
[].port (integer) β Port object will expose
[].target_port (integer) β
[].title (string) β (required)
-
POST
/services/
ΒΆ API endpoint that allows services to be edited or deleted.
- Request JSON Object
api_version (string) β API version used to deploy child object.
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
kind (string) β String representation of Kubernetes object kind (required)
kuid (string) β Objectβs UID in the cluster
namespace (string) β Live namespace the object is associated with. (required)
port (integer) β Port object will expose
target_port (integer) β
title (string) β (required)
- Status Codes
201 Created β
- Response JSON Object
api_version (string) β API version used to deploy child object.
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
kind (string) β String representation of Kubernetes object kind (required)
kuid (string) β Objectβs UID in the cluster
namespace (string) β Live namespace the object is associated with. (required)
port (integer) β Port object will expose
target_port (integer) β
title (string) β (required)
-
GET
/services/{id}/
ΒΆ API endpoint that allows services to be edited or deleted.
- Parameters
id (string) β UUID Auto field.
- Status Codes
200 OK β
- Response JSON Object
api_version (string) β API version used to deploy child object.
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
kind (string) β String representation of Kubernetes object kind (required)
kuid (string) β Objectβs UID in the cluster
namespace (string) β Live namespace the object is associated with. (required)
port (integer) β Port object will expose
target_port (integer) β
title (string) β (required)
-
PUT
/services/{id}/
ΒΆ API endpoint that allows services to be edited or deleted.
- Parameters
id (string) β UUID Auto field.
- Request JSON Object
api_version (string) β API version used to deploy child object.
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
kind (string) β String representation of Kubernetes object kind (required)
kuid (string) β Objectβs UID in the cluster
namespace (string) β Live namespace the object is associated with. (required)
port (integer) β Port object will expose
target_port (integer) β
title (string) β (required)
- Status Codes
200 OK β
- Response JSON Object
api_version (string) β API version used to deploy child object.
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
kind (string) β String representation of Kubernetes object kind (required)
kuid (string) β Objectβs UID in the cluster
namespace (string) β Live namespace the object is associated with. (required)
port (integer) β Port object will expose
target_port (integer) β
title (string) β (required)
-
PATCH
/services/{id}/
ΒΆ API endpoint that allows services to be edited or deleted.
- Parameters
id (string) β UUID Auto field.
- Request JSON Object
api_version (string) β API version used to deploy child object.
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
kind (string) β String representation of Kubernetes object kind (required)
kuid (string) β Objectβs UID in the cluster
namespace (string) β Live namespace the object is associated with. (required)
port (integer) β Port object will expose
target_port (integer) β
title (string) β (required)
- Status Codes
200 OK β
- Response JSON Object
api_version (string) β API version used to deploy child object.
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
kind (string) β String representation of Kubernetes object kind (required)
kuid (string) β Objectβs UID in the cluster
namespace (string) β Live namespace the object is associated with. (required)
port (integer) β Port object will expose
target_port (integer) β
title (string) β (required)
-
DELETE
/services/{id}/
ΒΆ API endpoint that allows services to be edited or deleted.
- Parameters
id (string) β UUID Auto field.
- Status Codes
204 No Content β
-
GET
/services/{id}/deploy/
ΒΆ Action to deploy the kubernetes resource to target cluster.
- Parameters
id (string) β UUID Auto field.
- Status Codes
200 OK β
- Response JSON Object
api_version (string) β API version used to deploy child object.
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
kind (string) β String representation of Kubernetes object kind (required)
kuid (string) β Objectβs UID in the cluster
namespace (string) β Live namespace the object is associated with. (required)
port (integer) β Port object will expose
target_port (integer) β
title (string) β (required)
-
GET
/services/{id}/remove/
ΒΆ Action to delete the kubernetes resource from the cluster/namespace.
- Parameters
id (string) β UUID Auto field.
- Status Codes
200 OK β
- Response JSON Object
api_version (string) β API version used to deploy child object.
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
kind (string) β String representation of Kubernetes object kind (required)
kuid (string) β Objectβs UID in the cluster
namespace (string) β Live namespace the object is associated with. (required)
port (integer) β Port object will expose
target_port (integer) β
title (string) β (required)
volumesΒΆ
-
GET
/volumes/
ΒΆ API endpoint that allows volumes to be edited or deleted.
- Status Codes
200 OK β
- Response JSON Object
[].cluster (string) β ForeignKey to TargetCluster object.
[].description (string) β
[].title (string) β (required)
-
POST
/volumes/
ΒΆ API endpoint that allows volumes to be edited or deleted.
- Request JSON Object
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
title (string) β (required)
- Status Codes
201 Created β
- Response JSON Object
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
title (string) β (required)
-
GET
/volumes/{id}/
ΒΆ API endpoint that allows volumes to be edited or deleted.
- Parameters
id (string) β UUID Auto field.
- Status Codes
200 OK β
- Response JSON Object
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
title (string) β (required)
-
PUT
/volumes/{id}/
ΒΆ API endpoint that allows volumes to be edited or deleted.
- Parameters
id (string) β UUID Auto field.
- Request JSON Object
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
title (string) β (required)
- Status Codes
200 OK β
- Response JSON Object
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
title (string) β (required)
-
PATCH
/volumes/{id}/
ΒΆ API endpoint that allows volumes to be edited or deleted.
- Parameters
id (string) β UUID Auto field.
- Request JSON Object
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
title (string) β (required)
- Status Codes
200 OK β
- Response JSON Object
cluster (string) β ForeignKey to TargetCluster object.
description (string) β
title (string) β (required)
-
DELETE
/volumes/{id}/
ΒΆ API endpoint that allows volumes to be edited or deleted.
- Parameters
id (string) β UUID Auto field.
- Status Codes
204 No Content β