Home assistant upgrade with stop and restart service

I found ‘systemctl’ under /bin folder and the script

#!/bin/dash
sudo /bin/systemctl stop home-assistant
sudo /home/homeassistant/homeassistant-update.sh
sudo /bin/systemctl start home-assistant

seems work correctly !

Thanks for your help !!!