Should I switch to an old 2010 iMac?

I’m currently running Hass.io on my Raspberry Pi 3 B. I’m using a Samsung Endurance 32gb microSD and a iPad charger as the power supply.

It runs fine 90% of the time but is quite slow overall. Loading the Logbook or History section can take up to a minute at times. Restarting can take 3-5minutes.

This morning, it crashed, so I restarted it and it is now verrrrry slow. I made a snapshot and tried downloading and it downloaded at 30KB/s. It did it about a month ago and I had to reinstall to fix it. I can’t be bothered reinstalling on a device where this will happen every month.

I have an old iMac I currently have lying around running Homebridge and Deepstack for my cameras and is running fine. Not sure about the exact specs but it is running a dual core i5 and 500gb 5400rpm hard drive.

Should I move my Hass.io setup to this Mac in a Docker container or virtual machine? Has anyone done this before?

It’s exactly how I run my instance (although on a MacBook Pro). I would not suggest running it natively in Docker for Mac. I did that for a long time and Docker for Mac has a few issues and my HA "system’ kept getting hung with thread and memory leak issues. I then went to Ubuntu in VirtualBox and that worked really well. I just recently made the jump to Hass.io but still in Virtual Box and couldn’t be happier. The system s rock solid.

I ran Home Assistant in virtualenv on my mac mini for a little bit. I wanted to move to docker, and jumped to a fanless, SSD-based NUC-style box. Later, I just installed Ubuntu on the mac mini without too much problem.

You might investigate doing that with your iMac and get a more “mainstream” server-type platform, Docker that’s well supported, etc. I have an older iMac, and it’s a bit of a pig, power-wise, for something that you’d run 24x7, something else to consider.

I think that even the 5400 RPM drive will be an improvement over the SD card…

You should definitely switch to the iMac. It will be considerably faster and a hard drive is much more reliable than the SD cards.

You have several options:

  1. Run it natively in a venv - in this case you might need to install/upgrade python3 to version 3.6 at least. You can easily use homebrew to do that.
  2. Run it in a linux virtual machine.

I’d stay away from docker, as docker for mac is using a linux virtual machine underneath, so you’ll get the same overhead as you do with option 2 above + docker overhead on top of that.

Option 3 would be to wipe macos and venture into installing linux on that mac if you’re not using it for anything else :wink:

I might try it to see the speed difference. I honestly don’t use the Mac for anything else so it would be pretty fun to spend a free day installing Linux on it. For now, because I don’t have much time and I prefer Hass.io, I’ll probably just try to install HassOS in VirtualBox. If I was to install Linux, would I just install Ubuntu then run Hass.io in a docker container there?

Probably the easiest method. I believe there are official vm images. I think it’s best to use a bridged virtual network adapter so that the VM can become part of your network with a separate IP address.

You can do containers and you can do venv install. I myself prefer the native way just so I can trim the negligible performance overhead of docker.