Skip to content

Instantly share code, notes, and snippets.

@Red-Eyed
Last active July 16, 2023 08:26
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Red-Eyed/efba5017d782fc8e881029aa482b3cbc to your computer and use it in GitHub Desktop.
Save Red-Eyed/efba5017d782fc8e881029aa482b3cbc to your computer and use it in GitHub Desktop.
python webdav server

Server: Install webdav server

python -m pip install wsgidav cheroot lxml

Server: Run web dav server

python -m wsgidav.server.server_cli -p60012 --root=/ --auth=anonymous -Hlocalhost

Client: Configure ssh config

Place next snippet to ~/.ssh/config. If this file doesn't exist: create it

Host webdav_host
  HostName 192.168.1.55 # ip of server
  User user 
  LocalForward 60012 localhost:60012 # port which will be forwarded from server to client

Client: connect to webdav server

ssh webdav_server -N

Client: mount directory

Windows

  1. Open File Explored : Windows+E
  2. Right click on This PC -> Map Network Drive
  3. Select drive letter
  4. In folder, enter http://localhost:600012

Linux

TBD: I don't need webdav for linux, there is sshfs

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment