Multiple Smart Home Devices Operating on Raspberry Pi - Remote Access

OK Guru’s,
I have a situation that I need some help with…
As an I.T Engineer Hobbyist, Here is what I have been up to. First Project, When my Pellet Stove Digital Board went out and I found out that it was going to be over $300.00 to replace it, I purchased my first Raspberry Pi device, a relay bank, components, and built GPIO code in python. System has ran for over a year now flawlessly. General operation is to remote into the box via SSH, and run the script file.
Then, As I was satisfied with this device during the winter, I decided to build a similar unit to run my swamp cooler during the summer. Works well!
Recently to add to my Pi Running my 3D Printer Via OCTIPrint, My Pellet Stove, My Swamp Cooler… I figured why not Home Assistant on a Pi to run my smart devices and have a nice customizable interface… So Home Assistant has been chosen for that. Here’s the snag and what I really need help with.
I have tried everything I can think of to get the remote GPIO feature to work, and have come up empty.
I converted my code over to GPIOZERO from standard GPIO code. when I run it on the local machine I am only able to turn on the relay for a period of time if I use the ‘time.sleep()’ function. But I cannot get the relays to turn on and stay on like I can with the normal GPIO code. I’ve seen others have has similar issues, but I have not found a resolution. Any Ideas?

End all result is this. I want to be able to have a button in the UI that I can push to turn on or off the remote pi GPIO relay device. similar to a light bulb or smart plug. but obviously the behind the scene action is running the remote Python script that does the function behind the scenes.