Possible to Automatically Restart a MacBook Running Home Assistant in VirtualBox After a Power Failure?

I’m exploring running Home Assistant Supervised in VirtualBox installed on an early 2011 MacBook Pro 13" with High Sierra as its OS. One thing that interests me is that because it is running on a laptop, the laptop’s battery can keep things running in the event of a power failure. Where I am running into problems is if the MacBook shuts down because the power did not come back on before the battery drained.

Is there anyway to make the MacBook automatically restart once the power comes back on and the battery has sufficiently charged? Typically one would just push the power button to make this happen but I’d like the restart not require any human action. I’ve tinkered with pmset acwake settings but no joy.

Thanks.