rsync -avz --delete /data/ user@remote:/backup/data/
Category: Self-Hosting
rsync -avz --delete /data/ user@remote:/backup/data/
Sync to remote and delete files on the destination that no longer exist locally — an exact mirror
Like rsync -avz but also deletes files at the destination that no longer exist at the source — creates an exact mirror.