For a while I used pm2 to deploy stuff. It's honestly a nifty little tool but I'm moving away into a docker based solution.
Initially I was thinking into having a CI build the images and push it to the server and so one but for my personal projects, it's too much. So I might just do a bash script to build the image, push it to the hub and then connect to ssh to pull the image and restart.
Regarding your script, could you share a template?