How can I move or rebootstrap devices?
Sometimes it can be useful to rebootstrap one or many devices. You might need to move them between different accounts or you just want to test something. This can be easily achieved like this:
Run the following commands (as root) on command line or include them in a script:
# sudo systemctl stop qbee-agent # sudo rm /etc/qbee/ -rf # sudo /opt/qbee/bin/qbee-bootstrap -k <bootstrap-key> # sudo systemctl start qbee-agent
Obviously these need to be included in a script if you want to do this on a large number of devices.
- you might want to open port 22 again before you stop the qbee agent
- when you stop the agent a reboot would start it again
- if the qbee directory has been removed the device cannot connect to the qbee backend anymore
- make sure you do not enter a state in which you loose remote access through qbee and CLI