-
Notifications
You must be signed in to change notification settings - Fork 0
/
kick_off_migration.yaml
31 lines (28 loc) · 1.24 KB
/
kick_off_migration.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
30
31
- name: Auth to kube with provision_data.users environment variables
community.okd.openshift_auth:
validate_certs: false
username: "{{ _user_name }}"
password: "{{ _user_password }}"
host: "{{ provision_data.openshift_api_server_url }}"
register: _auth_rez
- name: Block to call virt_plan role
environment:
K8S_AUTH_API_KEY: "{{ _auth_rez.k8s_auth.api_key }}"
K8S_AUTH_HOST: "{{ provision_data.openshift_api_server_url }}"
K8S_AUTH_VERIFY_SSL: "false"
VMWARE_VALIDATE_CERTS: "false"
VMWARE_HOST: "{{ vcenter_hostname }}"
VMWARE_PASSWORD: "{{ vcenter_password }}"
VMWARE_USER: "{{ vcenter_username }}"
block:
- name: Call role for users with vmware credentials in envrionment
ansible.builtin.include_role:
name: rlopez.ocp_virt.virt_plan
vars:
migration_namespace: "mtv-{{ _user_name }}"
migration_target_namespace: "vmexamples-{{ _user_name }}"
networkmap_name: "networkmap-{{ _user_name }}"
storagemap_name: "storagemap-{{ _user_name }}"
plan_name: "plan-{{ _user_name }}"
datastore: "{{ provision_data.vcenter_datastore }}"
user_selected_vm_names: "database-{{ _user_name }}\nwinweb01-{{ _user_name }}\nwinweb02-{{ _user_name }}"