darkwizard242.kubens

build-test release Ansible Role Maintainability Rating Reliability Rating Security Rating GitHub tag (latest SemVer) GitHub repo size

Ansible Role: kubens

This role installs kubens by default on Debian/Ubuntu and EL systems. kubens is a tool that makes it easy to switch between Kubernetes namespaces.

Requirements

None.

Role Variables

Here are the variables you can customize (found in defaults/main.yml):

Variables list:

kubens_app: kubens
kubens_version: 0.9.5
kubens_os: "{{ ansible_system | lower }}"
kubens_architecture_map:
  amd64: x86_64
  arm: arm64
  x86_64: x86_64
  armv6l: armv6
  armv7l: armv7
  aarch64: arm64
  32-bit: "386"
  64-bit: x86_64
kubens_dl_url: https://github.com/ahmetb/kubectx/releases/download/v{{ kubens_version }}/{{ kubens_app }}_v{{ kubens_version }}_{{ kubens_os }}_{{ kubens_architecture_map[ansible_architecture] }}.tar.gz
kubens_bin_path: /usr/local/bin
kubens_file_owner: root
kubens_file_group: root
kubens_file_mode: '0755'

Variables table:

Variable Description
kubens_app The application to install, which is kubens.
kubens_version The version to install; defaults to 0.9.5.
kubens_osarch Specifies the operating system type.
kubens_architecture_map Specifies the architecture type for OS.
kubens_dl_url The URL to download the kubens binary.
kubens_bin_path The path to place the kubens binary, defaults to /usr/local/bin.
kubens_file_owner The owner of the kubens binary file.
kubens_file_group The group for the kubens binary file.
kubens_file_mode The permission mode for the kubens binary file.

Dependencies

None

Example Playbook

To install kubens using an Ansible playbook:

- hosts: servers
  roles:
    - darkwizard242.kubens

To change the version of kubens:

- hosts: servers
  roles:
    - darkwizard242.kubens
  vars:
    kubens_version: 0.9.3

To install kubens in a different location:

- hosts: servers
  roles:
    - darkwizard242.kubens
  vars:
    kubens_bin_path: /bin/

License

MIT

Author Information

This role was created by Ali Muhammad.

Informazioni sul progetto

Installs/Uninstalls 'kubens', tool to switch between Kubernetes namespaces easily.

Installa
ansible-galaxy install darkwizard242.kubens
Licenza
mit
Download
2.4k
Proprietario
Senior DevOps/CloudOps Engineer. Dedicated to Automating everything I come across. Love to work on and learn new technologies/tools everyday!