Is there any way to change the target server name in the middle of the playbook? This is for windows.
Thanks and Regards,
Praveen Singh
Is there any way to change the target server name in the middle of the playbook? This is for windows.
Thanks and Regards,
Praveen Singh
Is there any way to change the target server name in the middle of the playbook? This is for windows.
Thanks and Regards,
Praveen Singh
Hello Praveen,
do you mind to explain which use case you have in mind?
Regards
Racke
Hello Stefan,
I am trying to create a playbook to perform the three below mentioned tasks which is to accomplish the database refresh. First two tasks (Database backup and Backup copy to destination server) are running fine but for the third one which is to restore the Database I need to change the host server as windows server 2. So I am not sure how I can achieve it. The playbook I am using is below:
Hello Stefan,
I am trying to create a playbook to perform the three below mentioned tasks which is to accomplish the database refresh.
First two tasks (Database backup and Backup copy to destination server) are running fine but for the third one which is
to restore the Database I need to change the host server as windows server 2. So I am not sure how I can achieve it. The
playbook I am using is below:1) Taking backup on remote windows server 1.
2) Copying that backup to another remote windows server 2.
3) Restoring that backup to remote windows server 2.
Hello Praveen,
I would put both servers into "hosts" and add a condition to each task:
Either
when: inventory_hostname == 'SQLSERVER'
or:
when: inventory_hostname == 'SERVER2'
Regards
Racke
Thank you so much Stefan. That worked.
Thanks and regards
Praveen Singh