SabreDAV is a powerful open-source WebDAV server that allows you to easily access your files over the internet. Here is a step-by-step guide on how you can install SabreDAV on macOS:
Open Terminal on your Mac.
Install PHP via Homebrew using the following command:
brew install php
Install Composer using the following command:
brew install composer
Download the latest version of SabreDAV using the following command:
composer create-project sabre/dav /var/www/html/sabredav
This command will download and install the latest version of SabreDAV in the "/var/www/html/sabredav" directory.
Create a Virtual Host for SabreDAV. SabreDAV should be accessed via a Virtual Host to serve its content. You can create a Virtual Host using the following command:
sudo nano /etc/apache2/other/sabredav.conf
This will open up a new file "sabredav.conf" in the nano text editor. Paste the following code into this file.
<VirtualHost *:80>
DocumentRoot "/var/www/html/sabredav/public"
ServerName sabredav.local
<Directory "/var/www/html/sabredav/public">
AllowOverride All
Order Allow,Deny
Allow from All
</Directory>
</VirtualHost>
This code creates a Virtual Host that listens on port 80 with the ServerName of "sabredav.local" and sets the DocumentRoot to "/var/www/html/sabredav/public".
Save the file by pressing "Control + O" and then exit the nano text editor by pressing "Control + X".
Restart Apache using the following command:
sudo apachectl restart
Access SabreDAV by opening a web browser and navigating to http://sabredav.local/. You should see the SabreDAV homepage.
Congratulations! You have successfully installed SabreDAV on your Mac using Homebrew and Composer. You can now configure SabreDAV to suit your needs and start using it to access your files via the internet.
If you want to self-host in an easy, hands free way, need an external IP address, or simply want your data in your own hands, give IPv6.rs a try!
Alternatively, for the best virtual desktop, try Shells!