Home
Blog
Rsync and Static Website
Updated
Dot Net Perls

Rsync and Static Website

Suppose you are making a website and want to have a static site generator. This is great for performance, but it means you need a way to deploy the files to a remote server. Rsync, a command-line tool, is ideal for this.

Over the years I have used various graphical FTP programs to deploy a statically-generated website, but rsync is faster and more reliable (and also free). Basically with rsync, one types in "rsync" and then the "from" directory (the local folder) and the "to" directory (the remote folder on a server).

With command-line flags it can support SSH so that it can perform a secure update of the website. Then, once the files are deployed, the remote web server (like Caddy or NGINX) will automatically serve the new files. While the exact usage of rsync is out of the scope of this post, it is available in WSL (Windows Subsystem for Linux) and macOS.

Dot Net Perls is a collection of pages with code examples, which are updated to stay current. Programming is an art, and it can be learned from examples.
Donate to this site to help offset the costs of running the server. Sites like this will cease to exist if there is no financial support for them.
Sam Allen is passionate about computer languages, and he maintains 100% of the material available on this website. He hopes it makes the world a nicer place.
No updates found for this page.
Home
Changes
© 2007-2025 Sam Allen