|
1 | | -# webdav-server |
| 1 | +# 🌐 Simple & Powerful WebDAV Server |
| 2 | + |
| 3 | +The **WebDAV Server** is a lightweight, customizable solution built with Docker, designed for secure file sharing and remote access. It offers flexible configuration options and supports multiple authentication methods, including basic authentication, LDAP, and OAuth. With minimal setup, this server is ideal for both personal and enterprise use cases where easy deployment and secure access are key. |
| 4 | + |
| 5 | + |
| 6 | +> [!NOTE] |
| 7 | +> The pre-built Docker image is available at: **`ghcr.io/vaggeliskls/webdav-server:latest`** |
| 8 | +
|
| 9 | +## 📦 Prerequisites |
| 10 | + |
| 11 | +Before getting started, make sure you have the following: |
| 12 | + |
| 13 | +- **Docker** version **20.0** or higher |
| 14 | +- Basic knowledge of Docker and WebDAV |
| 15 | + |
| 16 | +## 🚀 Key Features |
| 17 | + |
| 18 | +- **Effortless Deployment**: Set up a fully operational WebDAV server quickly using Docker. |
| 19 | +- **Flexible Authentication**: |
| 20 | + - Basic Authentication 🛡️ |
| 21 | + - LDAP Authentication 🛡️ |
| 22 | + - OAuth Authentication 🛡️ |
| 23 | +- **Proxy-Ready**: Easily integrate with reverse proxies to add more authentication layers. |
| 24 | +- **Authentication is Optional**: The server runs without authentication by default, allowing flexibility for your setup. |
| 25 | + |
| 26 | +## 🔧 Authentication Setup |
| 27 | + |
| 28 | +You can enable various authentication mechanisms using environment variables in a `.env` file. Here’s how to configure each one: |
| 29 | + |
| 30 | +### 🔐 Basic Authentication |
| 31 | + |
| 32 | +To enable basic authentication with username and password protection: |
| 33 | + |
| 34 | +```bash |
| 35 | +BASIC_AUTH_ENABLED=true |
| 36 | +BASIC_AUTH_REALM=WebDAV |
| 37 | +BASIC_USERS=alice:alice123 bob:bob123 |
| 38 | +``` |
| 39 | + |
| 40 | +### 🔐 OAuth Authentication |
| 41 | +OAuth authentication (example with Google OAuth) configuration: |
| 42 | +``` |
| 43 | +OAUTH_ENABLED=true |
| 44 | +OAUTH_CLIENT_ID=1234567890-abcdefghijklm.apps.googleusercontent.com |
| 45 | +OAUTH_CLIENT_SECRET=ABC123def456GHI789jkl0mnopqrs |
| 46 | +OAUTH_SCOPE="openid email profile" |
| 47 | +OAUTH_REDIRECT_URI=http://localhost |
| 48 | +OAUTH_METADATA_URL="https://accounts.google.com/.well-known/openid-configuration" |
| 49 | +OAUTH_CRYPTO_PASSPHRASE=mysecurepassphrase |
| 50 | +OAUTH_FORWARDED_HEADER=X-Forwarded-Host,X-Forwarded-Port,X-Forwarded-Proto |
| 51 | +``` |
| 52 | + |
| 53 | +### 🔐 LDAP Authentication |
| 54 | +LDAP integration for centralized user management: |
| 55 | +``` |
| 56 | +LDAP_ENABLED=true |
| 57 | +LDAP_URL=ldaps://ldap.example.com |
| 58 | +LDAP_ATTRIBUTE=uid |
| 59 | +LDAP_BASE_DN=ou=users,dc=example,dc=com |
| 60 | +LDAP_BIND_DN=uid=admin,ou=users,dc=example,dc=com |
| 61 | +LDAP_BIND_PASSWORD=securepassword |
| 62 | +``` |
| 63 | + |
| 64 | +## 📖 Usage Guide |
| 65 | + |
| 66 | +1. Clone Repository |
| 67 | + |
| 68 | +2. Start the WebDAV Server: `docker compose up --build` |
| 69 | + |
| 70 | +3. Open http://localhost or your server's IP in a browser or WebDAV client to start using the service. |
| 71 | + |
| 72 | + |
| 73 | +## 📚 References |
| 74 | + |
| 75 | +- [Docker Apache WebDAV](https://github.com/mgutt/docker-apachewebdav) |
| 76 | +- [What is WebDAV?](https://www.jscape.com/blog/what-is-webdav) |
0 commit comments