Migrating UniFi Controller

My goal for the year is to not nickle and dime myself as much.
One of the things I am looking at is moving as many of the services off the cloud as possible. I want to focus on tangible things I pay for once. At this point I have paid for may Raspberry Pi’s or some small form factor computers in cloud hosting costs.

As an intermediate step I am interested in moving my UniFi devices to Ubiquiti’s controller.

I have about 20 UniFi devices spread over 5 sites over a geographical distance best measured in hours of driving. I am looking for suggestions on the most painless way to accomplish this.

My knee jerk reaction is to change the A record to point at ubiquiti’s console after I import everything I need to, then just repeat the process down the road when I am ready to move. I am sure I am about to find out this is impossible, and a headache, that is why I am here. Please feel free to tell me why it isn’t going to work, but please include why, if there is a workaround, and how you would go about it.

Have a look at this, you install the new Unifi controller and move the devices to the new setup

Thanks Paul,
I know Tom or Chris from Crosstalk had a video on the subject, but I wasn’t looking forward to searching for it.