k8s-namespace-absent

Description

n/a

Variables

Name Type Default Description

api_version

string v1

Use to specify the API version. Use to create, delete, or discover an object without providing a full resource definition. Use in conjunction with kind, name, and namespace to identify a specific object.

name

string --

The namespace name.

Code

args:
  api_version:
    doc:
      short_help: The API version.
      help: |
        Use to specify the API version. Use to create, delete, or discover an object without providing a full resource definition. Use in conjunction with kind, name, and namespace to identify a specific object.
    type: string
    required: true
    default: v1
  name:
    doc:
      short_help: The namespace name.
    type: string
    required: false
#  kind:
#    doc:
#      short_help: The object model type.
#      help: |
#        Use to specify an object model. Use to create, delete, or discover an object without providing a full resource definition. Use in conjunction with api_version, name, and namespace to identify a specific object.
#    type: string
#    required: true

frecklets:
- frecklet:
    name: k8s
    type: ansible-module
    properties:
      idempotent: true
      elevated: false
    resources:
      python-package:
      - openshift
    desc:
      short: "removing k8s namespace '{{:: name ::}}'"
  task:
    become: false
    delegate_to: localhost
  vars:
    api_version: '{{:: api_version ::}}'
    kind: namespace
    name: '{{:: name ::}}'
    state: absent
frecklecute k8s-namespace-absent --help

Usage: frecklecute k8s-namespace-absent [OPTIONS]

  n/a

Options:
  --api-version API_VERSION  The API version.
  --name NAME                The namespace name.
  --help                     Show this message and exit.
# -*- coding: utf-8 -*-


#
# module path: pycklets.k8s_namespace_absent.K8sNamespaceAbsent
#


from dataclasses import dataclass
from pyckles import AutoPycklet
from typing import *    # noqa

@dataclass
class K8sNamespaceAbsent(AutoPycklet):
    """No documentation available.

       Args:
         api_version: The API version.
         name: The namespace name.

    """

    FRECKLET_ID = "k8s-namespace-absent"

    api_version: str = None
    name: str = None


    def __post_init__(self):
        super(K8sNamespaceAbsent, self).__init__(var_names=["api_version", "name"])


frecklet_class = K8sNamespaceAbsent
# -*- coding: utf-8 -*-


#
# module path: pycklets.k8s_namespace_absent.K8sNamespaceAbsent
#


from pyckles import AutoPycklet

class K8sNamespaceAbsent(AutoPycklet):
    """No documentation available.

       Args:
         api_version: The API version.
         name: The namespace name.

    """

    FRECKLET_ID = "k8s-namespace-absent"

    def __init__(self, api_version="v1", name=None):

        super(K8sNamespaceAbsent, self).__init__(var_names=["api_version", "name"])
        self._api_version = api_version
        self._name = name

    @property
    def api_version(self):
        return self._api_version

    @api_version.setter
    def api_version(self, api_version):
        self._api_version = api_version

    @property
    def name(self):
        return self._name

    @name.setter
    def name(self, name):
        self._name = name



frecklet_class = K8sNamespaceAbsent