Control machine. Install pip pip install ansible Edit the hosts table hostname port username password web01 22 root root_passwd run python ssh_copy_id.py enjoy ansible