I kinda do this with a Raspberry Pi currently using OpenHAB on OpenHabianPi[0]. I was going to link it all up with Mycroft[1] but I havent setup my own version of Mycroft just yet. I might just buy one to support the project.
Up next is security cameras using MotionEyeOS[2] and Raspberry Pi Zero W's.
You really don't have to pay millions of dollars to automate your home. My thermostats use technology called Z-Wave for which there is a USB[3] adapter available on Amazon, for about $45 I turned 2 different Thermostats into Nest-like thermostats that I fully control myself, if my pi dies, the usb device still has them synched.
All in my house, all in my control and managed by yours truly.
[0]: https://www.openhab.org/docs/installation/openhabian.html#ra...
[1]: https://mycroft.ai/
[2]: https://github.com/ccrisan/motioneyeos
[3]: https://www.amazon.com/Aeotec-Z-Stick-Z-Wave-create-gateway/...
Final thought: If I ever get Mycroft setup, I'd essentially have a robot in my home running off a Raspberry Pi. He wouldn't move (wouldn't need him to) but he would do whatever I wish. For now openHAB has a UI for me.
Edit: Forgot to mention that openHAB is also scriptable, and even has a bit of IFTTT type of capacity internally.