1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21
- name: Pacman keyring + Python installation delegate_to: localhost ansible.builtin.shell: | expect <<EOD spawn sshpass -p alarm ssh \ -o UserKnownHostsFile=/dev/null \ -o StrictHostKeyChecking=no \ -o PubkeyAuthentication=false \ alarm@{{ inventory_hostname }} \ "su -c \"touch SUDOTEST; touch SUDOTEST2; touch SUDOTEST3\"" expect "Password: " send -- "root\r" interact EOD #spawn sshpass -p alarm ssh -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no -o PubkeyAuthentication=false alarm@{{ inventory_hostname }} "su -c \"touch SUDOTEST\; touch SUDOTEST2\; touch SUDOTEST3\"" #spawn sshpass -p alarm ssh -o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no -o PubkeyAuthentication=false alarm@{{ inventory_hostname }} "su -c \"pacman-key --init\; pacman-key --populate archlinuxarm\; pacman --noconfirm -S python\""