Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature Request: Hide dir if it not allow in user rules #67

Open
xiaolei0125 opened this issue Apr 14, 2021 · 2 comments
Open

Feature Request: Hide dir if it not allow in user rules #67

xiaolei0125 opened this issue Apr 14, 2021 · 2 comments

Comments

@xiaolei0125
Copy link

Can hide some dir(not show in webdav client) if these dir was not allow in user rules config?
I don't wants some users know the dir exist if they has no permisson for those dir. Thanks

@changfeng98
Copy link

Have you found a solution to this problem? I want to to solve the problem too.

@mofazhe
Copy link

mofazhe commented Aug 17, 2024

I solved this problem by creating a soft link, and it needs to be executed manually.

Here is an example:

  1. Execute this command to create a soft link
# The first path is outside of docker
# The second path is inside docker
ln -s "/etc/webdav/user/test/show-the-file" "/data/show-the-file"
  1. Part of webdav configuration
users:
  - username: test
    password: "your password"
    permissions: CURD
    directory: /user/test
  1. Docker compose configuration
version: "3"

services:
  webdav:
    image: hacdias/webdav
    container_name: webdav
    restart: unless-stopped
    volumes:
      - "/etc/webdav/config.yaml:/config.yaml:ro"
      - "/etc/webdav/user:/user"
      - "/your/shared/path:/data"
    ports:
      - "6065:6065"
    command: -c /config.yaml
  1. This test user will only be able to see part of the content of the created soft link

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants