First attempt at ansiblization of openshift/modernpaste
Signed-off-by: Ricky Elrod <codeblock@fedoraproject.org>
This commit is contained in:
parent
af2fac3977
commit
eb7a002027
9 changed files with 216 additions and 0 deletions
18
roles/openshift/object/tasks/main.yml
Normal file
18
roles/openshift/object/tasks/main.yml
Normal file
|
@ -0,0 +1,18 @@
|
|||
- name: Create temporary file
|
||||
tempfile: state=file
|
||||
register: tmpfile
|
||||
run_once: true
|
||||
|
||||
- name: Copy template to temporary file ({{tmpfile.path}})
|
||||
template: src={{ansible}}/roles/openshift-apps/{{app}}/templates/{{template}} dest={{tmpfile.path}}.yml
|
||||
when: template is defined
|
||||
run_once: true
|
||||
|
||||
- name: Copy file to temporary file ({{tmpfile.path}})
|
||||
copy: src={{ansible}}/roles/openshift-apps/{{app}}/files/{{file}} dest={{tmpfile.path}}.yml
|
||||
when: file is defined
|
||||
run_once: true
|
||||
|
||||
- name: Call `oc apply` on the copied file
|
||||
shell: oc -n {{app}} apply -f {{tmpfile.path}}.yml
|
||||
run_once: true
|
Loading…
Add table
Add a link
Reference in a new issue