summaryrefslogtreecommitdiffstats
path: root/roles/lib_openshift/src/doc
diff options
context:
space:
mode:
authorThomas Wiest <twiest@redhat.com>2017-01-19 16:16:19 -0500
committerThomas Wiest <twiest@redhat.com>2017-01-25 13:52:41 -0500
commit8f06d5e59f4bfb138b55569431f665f21437ff6c (patch)
tree1c00a730e35936f34743ca54f89a4cc6e0cd3e06 /roles/lib_openshift/src/doc
parentd8fee0cc8441812cdd5e7aaae815adad7a9bbee7 (diff)
downloadopenshift-8f06d5e59f4bfb138b55569431f665f21437ff6c.tar.gz
openshift-8f06d5e59f4bfb138b55569431f665f21437ff6c.tar.bz2
openshift-8f06d5e59f4bfb138b55569431f665f21437ff6c.tar.xz
openshift-8f06d5e59f4bfb138b55569431f665f21437ff6c.zip
Added oc_secret to lib_openshift.
Diffstat (limited to 'roles/lib_openshift/src/doc')
-rw-r--r--roles/lib_openshift/src/doc/secret116
1 files changed, 116 insertions, 0 deletions
diff --git a/roles/lib_openshift/src/doc/secret b/roles/lib_openshift/src/doc/secret
new file mode 100644
index 000000000..5c2bd9bc0
--- /dev/null
+++ b/roles/lib_openshift/src/doc/secret
@@ -0,0 +1,116 @@
+# flake8: noqa
+# pylint: skip-file
+
+DOCUMENTATION = '''
+---
+module: oc_secret
+short_description: Module to manage openshift secrets
+description:
+ - Manage openshift secrets programmatically.
+options:
+ state:
+ description:
+ - If present, the secret will be created if it doesn't exist or updated if different. If absent, the secret will be removed if present. If list, information about the secret will be gathered and returned as part of the Ansible call results.
+ required: false
+ default: present
+ choices: ["present", "absent", "list"]
+ aliases: []
+ kubeconfig:
+ description:
+ - The path for the kubeconfig file to use for authentication
+ required: false
+ default: /etc/origin/master/admin.kubeconfig
+ aliases: []
+ debug:
+ description:
+ - Turn on debug output.
+ required: false
+ default: False
+ aliases: []
+ name:
+ description:
+ - Name of the object that is being queried.
+ required: false
+ default: None
+ aliases: []
+ namespace:
+ description:
+ - The namespace where the object lives.
+ required: false
+ default: default
+ aliases: []
+ files:
+ description:
+ - A list of files provided for secrets
+ required: false
+ default: None
+ aliases: []
+ delete_after:
+ description:
+ - Whether or not to delete the files after processing them.
+ required: false
+ default: false
+ aliases: []
+ contents:
+ description:
+ - Content of the secrets
+ required: false
+ default: None
+ aliases: []
+ force:
+ description:
+ - Whether or not to force the operation
+ required: false
+ default: false
+ aliases: []
+ decode:
+ description:
+ - base64 decode the object
+ required: false
+ default: false
+ aliases: []
+author:
+- "Kenny Woodson <kwoodson@redhat.com>"
+extends_documentation_fragment: []
+'''
+
+EXAMPLES = '''
+- name: create secret
+ oc_secret:
+ state: present
+ namespace: openshift-infra
+ name: metrics-deployer
+ files:
+ - name: nothing
+ path: /dev/null
+ register: secretout
+ run_once: true
+
+- name: get ca from hawkular
+ oc_secret:
+ state: list
+ namespace: openshift-infra
+ name: hawkular-metrics-certificate
+ decode: True
+ register: hawkout
+ run_once: true
+
+- name: Create secrets
+ oc_secret:
+ namespace: mynamespace
+ name: mysecrets
+ contents:
+ - path: data.yml
+ data: "{{ data_content }}"
+ - path: auth-keys
+ data: "{{ auth_keys_content }}"
+ - path: configdata.yml
+ data: "{{ configdata_content }}"
+ - path: cert.crt
+ data: "{{ cert_content }}"
+ - path: key.pem
+ data: "{{ osso_site_key_content }}"
+ - path: ca.cert.pem
+ data: "{{ ca_cert_content }}"
+ register: secretout
+'''