Backup/Restore script extract from (NextCloud VM)

While watching the last NextCloud update run by the script “” (from the NextCloud VM), I noticed that it was actually performing a backup and then a restore.

Is that code available as a separate backup/restore script?

Within vm/ at master · nextcloud/vm · GitHub, the backup sequence starts around line 555.

Is there a backup and restore only script available that does the same as in the script?