Hi !
To run some long lasting commands from Home Assistant I created a small project that may be interesting to others.
I’m using it to run backups, long lasting scripts to fetch my bank account transactions, download my photos from iCloud, etc…
I have been using it for quite some time now and just finished cleaning it up to be usable by others.
If you have similar needs feel free to give it a try