Differences
This shows you the differences between two versions of the page.
| Both sides previous revision Previous revision Next revision | Previous revision Next revisionBoth sides next revision | ||
| docs:guide-user:services:nas:webdav [2023/01/20 16:17] – [Browser UI for the WebDAV share] stokito | docs:guide-user:services:nas:webdav [2023/03/18 20:24] – [Test it] removed cadaver stokito | ||
|---|---|---|---|
| Line 8: | Line 8: | ||
| ==== WebDAV with Lighttpd ==== | ==== WebDAV with Lighttpd ==== | ||
| - | Assuming that USB drive is mounted to ''/ | + | First of all if you already have the Lighttpd then update it and it's modules to avoid conflicts: |
| + | <code bash> | ||
| + | opkg update | ||
| + | opkg list-upgradable | cut -f 1 -d ' ' | grep lighttpd | xargs opkg upgrade | ||
| + | </ | ||
| + | |||
| + | Assuming that USB drive is mounted to ''/ | ||
| <code bash> | <code bash> | ||
| - | mkdir -p / | + | mkdir -p / |
| - | chown http: | + | chown http: |
| cat << " | cat << " | ||
| $HTTP[" | $HTTP[" | ||
| - | server.document-root := "/srv/ | + | server.document-root := "/mnt/ |
| auth.backend = " | auth.backend = " | ||
| auth.backend.plain.userfile = "/ | auth.backend.plain.userfile = "/ | ||
| Line 21: | Line 27: | ||
| "/ | "/ | ||
| ) | ) | ||
| + | auth.cache = (" | ||
| } | } | ||
| EOF | EOF | ||
| Line 54: | Line 61: | ||
| To connect to WebDAV see [[https:// | To connect to WebDAV see [[https:// | ||
| - | To test WebDAV from command line use '' | + | A quick test can be done with a '' |
| - | + | ||
| - | < | + | |
| - | cadaver http:// | + | |
| - | Authentication required for webdav on server `192.168.1.1': | + | |
| - | Username: youruser | + | |
| - | Password: | + | |
| - | dav:/ | + | |
| - | Listing collection `/ | + | |
| - | README.txt | + | |
| - | dav:/ | + | |
| - | Displaying `/ | + | |
| - | It works! | + | |
| - | dav:/ | + | |
| - | Connection to `192.168.1.1' | + | |
| - | </ | + | |
| - | + | ||
| - | If you don't want to install the cadaver you can test with a '' | + | |
| <code bash> | <code bash> | ||
| - | curl -u youruser -X PROPFIND -H "Depth: 1" | + | curl -u youruser:pass -X PROPFIND -H 'Depth: 1' |
| </ | </ | ||
| + | You must see a 207 status code and XML response with directory listing. | ||
| + | |||
| + | See more details and examples [[https:// | ||
| ==== Don't forget about encryption! ==== | ==== Don't forget about encryption! ==== | ||
| Please note that you must configure HTTPS if you are going to access your files from internet. | Please note that you must configure HTTPS if you are going to access your files from internet. | ||
| - | See [[https:// | + | You'll need to [[docs: |
| ==== Browser UI for the WebDAV share ==== | ==== Browser UI for the WebDAV share ==== | ||
| Line 85: | Line 78: | ||
| <code html> | <code html> | ||
| - | cat << EOF > /srv/ | + | cat << EOF > /mnt/ |
| < | < | ||
| <html lang=" | <html lang=" | ||
| Line 94: | Line 87: | ||
| </ | </ | ||
| < | < | ||
| - | <script src=" | + | <script src=" |
| </ | </ | ||
| </ | </ | ||
| Line 106: | Line 99: | ||
| == Online apps and PWAs == | == Online apps and PWAs == | ||
| - | You can also try an online apps that can connect directly to your WebDAV share. | + | You can also try an online apps that can connect directly to your WebDAV share to backup data. Some notable apps: |
| * [[https:// | * [[https:// | ||
| * [[https:// | * [[https:// | ||
| - | * [[https://app.keeweb.info/|KeeWeb]] a password manager | + | * [[https://buttercup.pw/|Buttercup]] a password manager |
| - | * [[https://katomaso.github.io/webdave/|webdave]] a file manager. | + | * [[https://app.keeweb.info/|KeeWeb]] a password |
| - | You' | + | To allow online apps to connect with your WebDAV it need a CORS enabled. |
| Here is an example [[https:// | Here is an example [[https:// | ||
| == Useful Apps == | == Useful Apps == | ||
| Useful mobile apps that supports WebDAV sync: | Useful mobile apps that supports WebDAV sync: | ||
| - | * [[https:// | + | |
| - | * [[https:// | + | * [[https:// |
| + | |||
| ==== Links and docs ==== | ==== Links and docs ==== | ||
| * [[https:// | * [[https:// | ||
| * [[https:// | * [[https:// | ||
| * [[https:// | * [[https:// | ||
| - | * [[https:// | + | * [[https:// |
| * [[https:// | * [[https:// | ||
| + | ==== ZeroConf autodiscovery ==== | ||
| + | You can advertise a WebDAV share with [[docs: | ||
| + | Then it will be seen in Network folder of a file manager in GNOME and KDE and can be [[https:// | ||
| + | |||
| + | Install the umdns package with '' | ||
| + | |||
| + | <code - / | ||
| + | { | ||
| + | " | ||
| + | " | ||
| + | " | ||
| + | " | ||
| + | " | ||
| + | " | ||
| + | ] | ||
| + | } | ||
| + | } | ||
| + | </ | ||
| + | |||
| + | The reload the umdns service with: '' | ||