Automatically install mender client on RPI4

Hi,
I was wondering if there was the chance to set up a script to run to automatically install and connect any of my Raspberry Pi 4 devices to my Mender Dashboard.
At the moment to do that I have to access the dashboard, click on add device, following the procedure copying the code provided, and pasting it on my device.
I would like to have a script that downloads, install and connect the client to my dashboard and, the only thing I have to do is to accept it from the dashboard.
My idea was to put on a script the code provided by the Mender dashboard while trying to add a new device but, I guess, the code is unique everytime a new device is added, isn’t it?

It sounds pretty strange to me that everyone in the world are adding devices manually everytime…
UP

Hi Nico,

this should be perfectly possible to automate, sure. Does the unattended installation as documented here work for you? You can get the needed credential token from your dashboard.

If something is missing, or doesn’t work for you, please tell me a little bit more about your way of provisioning (especially, which OS and how the image is being built) so we can improve.

Thanks!
Josef

1 Like

thanks! It was exactly what I was looking for