motdotla / ansible-pi Goto Github PK
View Code? Open in Web Editor NEWQuickly setup your Raspberry Pi - particularly WIFI settings.
Quickly setup your Raspberry Pi - particularly WIFI settings.
Hi,
I'm running this on macOS 10.12.5, python 2.7.13, ansible 2.3.0.0. I get this error when I try to run the playbook:
$ ansible-playbook playbook.yml -i hosts --ask-pass --become -c paramiko
SSH password:
PLAY [Ansible Playbook for configuring brand new Raspberry Pi] *********************************************************************************************************************************************
TASK [Gathering Facts] *************************************************************************************************************************************************************************************
fatal: [192.168.1.xxx]: UNREACHABLE! => {"changed": false, "msg": "[Errno None] Unable to connect to port 22 on 192.168.1.xxx", "unreachable": true}
to retry, use: --limit @/Users/[username]/Downloads/ansible-pi/playbook.retry
PLAY RECAP *************************************************************************************************************************************************************************************************
192.168.1.xxx : ok=0 changed=0 unreachable=1 failed=0
Pushed the config changes and updated the apt packages just fine, but failed to reboot at the end.
fatal: [192.168.1.80]: FAILED! => {"changed": true, "cmd": ["/sbin/reboot", "-t", "now"], "delta": "0:00:00.045698", "end": "2016-02-18 11:20:00.375066", "failed": true, "rc": 1, "start": "2016-02-18 11:20:00.329368", "stderr": "/sbin/reboot: invalid option -- 't'", "stdout": "", "stdout_lines": [], "warnings": []}
You don't need the -t option for reboot, I believe that /sbin/reboot
would suffice in the Playbook?
There is an issue open for this with Ansible ansible/ansible#21269
A workaround is suggested here ansible/ansible#14237 (comment) which worked for me
- set_fact:
real_ansible_host: "{{ ansible_host }}"
...
- name: "Wait for Raspberry PI to come back"
local_action: wait_for host={{ real_ansible_host }} port=22 state=started delay=10
become: false
Hi, the site not work anymore, could you show us another source for requirement ?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.