forked from r3dact3d/OpenShift4-Ansible-Roles
-
Notifications
You must be signed in to change notification settings - Fork 0
/
day-2-ops.yaml
29 lines (26 loc) · 820 Bytes
/
day-2-ops.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
---
- name: Run ansible playbook
hosts: localhost
vars:
manifests_dir: "{{ lookup('env','GITHUB_WORKSPACE') }}/manifests"
kubeconfig_path: "{{ lookup('env','KUBECONFIG') }}"
environment:
KUBECONFIG: "{{ kubeconfig_path }}"
pre_tasks:
- name: Create directory for all manifests
file:
path: "{{ manifests_dir }}"
state: directory
mode: 0775
- name: Get output from pip show openshift command
command: pip show openshift
ignore_errors: true
changed_when: false
register: reg_pip_module_openshift_installed
- name: Set fact for openshift module
set_fact:
pip_module_openshift_installed: "{{ reg_pip_module_openshift_installed.rc }}"
tasks:
- name: Include day_2_ops role
include_role:
name: day_2_ops