2
호스트 인벤토리에 100 개의 호스트가 있습니다.호스트 인벤토리에서 오름차순으로 호스트 가져 오기 - 가능
[workstations-new]
de001pc[100:201] ansible_connection=ssh ansible_ssh_user=root
내가 ansible-각본 명령을 실행하면 : 호스트 - 재고은 다음과 같다
ansible-playbook playbooks/linux/uptime.yml -i hosts-inventory --extra-vars "hosts=workstations-new" -k
모든 호스트에 그것을 실행되고 있지만, 오름차순으로 호스트를하지 않습니다. 그것은 (103, 14, 102, 100, ...)을 비 위해 호스트를 취
예 :
TASK: [uptime machine] ********************************************************
changed: [de001pc103]
changed: [de001pc104]
changed: [de001pc102]
changed: [de001pc100]
changed: [de001pc101]
changed: [de001pc107]
changed: [de001pc106]
changed: [de001pc108]
changed: [de001pc109]
changed: [de001pc110]
changed: [de001pc116]
changed: [de001pc112]
................................................
가 어떻게 오름차순으로 호스트를 취할 명령을 실행할 수 있습니까?
답변 해 주셔서 감사합니다. 그것은 많은 도움이됩니다. – Romulus