This sample playbook will submit the Allocate Volumes with Smart Provisioning (02.93.00) service.
- Configure ansible.cfg and environment variables.
- Confirm whether the service to run exists in advance. If it does not exist, create it.
- Deploy the linkage module.
- Encrypt auth_info.yml with the ansible-vault command.
- Enable SSL settings between Ops Center Automator and Ansible and between Common Services and Ansible.
- Edit the values to match the running environment. The files where the variables are set are as follows.
File path To set roles/allocateVolumes/vars/main.yml Service settings
Task settings
Service parameters
connection_info_var/automation_software_server1.yml Ops Center Automator server and Common Services server information connection_info_var/auth_info.yml Authenication information (for Vault) roles/allocateVolumes/tasks/submitAllocateVolumesService.yml Uncomment the following lines if you use a Common Services user to access the Ops Center Automator server. #cs_host: "{{automation_software_cs_host}}"
#cs_port: "{{automation_software_cs_port}}"
- Run the following command:
$ansible-playbook AllocateVolumes_Playbook.yml --extra-vars "@connection_info_var/automation_software_server1.yml" --extra-vars "@connection_info_var/auth_info.yml" --ask-vault-pass