New k8s_facts module

Strip out the facts parts of the k8s module into a new simpler
module that deals with querying for facts, also allowing
field and label selectors
This commit is contained in:
Will Thames 2018-06-22 08:24:52 +10:00 committed by Toshio Kuratomi
parent ffba0a5d99
commit 895c512596
3 changed files with 183 additions and 15 deletions

View file

@ -30,6 +30,7 @@ description:
- Pass the object definition from a source file or inline. See examples for reading
files and using Jinja templates.
- Access to the full range of K8s APIs.
- Use the M(k8s_facts) module to obtain a list of items about an object of type C(kind)
- Authenticate using either a config file, certificates, password or token.
- Supports check mode.
@ -80,21 +81,6 @@ EXAMPLES = '''
state: present
src: /testing/service.yml
- name: Get an existing Service object
k8s:
api_version: v1
kind: Service
name: web
namespace: testing
register: web_service
- name: Get a list of all service objects
k8s:
api_version: v1
kind: ServiceList
namespace: testing
register: service_list
- name: Remove an existing Service object
k8s:
state: absent