kubernetes

package
v0.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 5, 2021 License: MIT Imports: 10 Imported by: 0

Documentation

Overview

Package kubernetes will manage all kubernetes pods requirements

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Client

func Client() (c *kubernetes.Clientset, err error)

Client return requirements to be able to connect to kubernetes cluster with the program running inside or outside of the cluster

func CreateNamespace

func CreateNamespace(clientset *kubernetes.Clientset, namespace string) (err error)

CreateNamespace permit to create namespace

func CreatePod

func CreatePod(clientset *kubernetes.Clientset, m models.Pods) (podName string, err error)

CreatePod permit to create pod inside of specified namespace

func CreateServiceAccountName

func CreateServiceAccountName(clientset *kubernetes.Clientset, namespace string, serviceAccount string) (serviceAccountName string, err error)

CreateServiceAccountName permit to create service account that will be used while creating the pod

func DeleteNamespace

func DeleteNamespace(clientset *kubernetes.Clientset, namespace string) (err error)

DeleteNamespace permit to delete created namespace

func DeletePod

func DeletePod(clientset *kubernetes.Clientset, namespace string, podName string) (err error)

DeletePod permit to delete pod inside of specified namespace

func GetNamespace

func GetNamespace(clientset *kubernetes.Clientset, namespace string) (err error)

GetNamespace check if namespace defined for jobs exist or not

func GetServiceAccountName

func GetServiceAccountName(clientset *kubernetes.Clientset, namespace string, serviceAccount string) (err error)

GetServiceAccountName permit to get service account in specified namespace

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL