Acces public share folder from anywhere

  • Hello everyone !

    New OMV user here ;)


    I am using OMV version 7.2.1-1 (SANDWORM), and i have a share setup in witch the file public is available.

    I want this file te be accessed easely in read and download for anyone anywhere without any login.


    I tried using webdav on the OMV server and well it kinda works, and you can try it too by goint to: nas.mathieujordan.be/webdav


    Only problem is when i put a file in the public folder, like the test.txt that is in there, i cannot download it from the webdav, nor open it by clicking as it tries to redirect to: nas.mathieujordan.be/test.txt.

    Witch is obviously not a usable URL in OMV, and so gives an expected 404 fatal error.


    Can you help me resolve this issue, and / or maybe give me another more suitable solution to resolve my problem ? :)


    Thank you all !

  • Hi,

    In your link : nas.mathieujordan.be/webdav

    I can see a file : test.txt (13-Jun-2024 10:53)


    But if I click on this file, i got an error #404.

    Because the link to this file is :

    "nas.mathieujordan.be/test.txt"

    ...when it should be pointing

    nas.mathieujordan.be/webdav/test.txt


    ...maybe this will put you on the right way ;) :thumbup:


    Your file (test.txt) contains this text :

    Code
    If you can read this, it means my problem is solved !
    
    Thank you for trying to help me though <3


  • I found a workaround.

    There is an error in the nginx configuration, which the OMV-webdav plugin creates.


    Change in the file (created by OMV webdav plugin)

    Code
    /etc/nginx/openmediavault-webgui.d/openmediavault-webdav.conf

    the keyword "alias" to "root":


    For example:

    Change

    Code
    alias /srv/dev-disk-by-uuid-108A908E8A907248/transfer/;

    to

    Code
    root /srv/dev-disk-by-uuid-108A908E8A907248/transfer/;


    But OMV overwrites your changes if you save the webdav plugin settings in the web interface.

  • Thanks to all of you for your answers !


    I tried and finally settled on the fact that i can use the filebrowser plugin to create a public share available to anyone with the link so it does the job :)


    Have a nice one !

  • UPDATE :

    I just played with the config file a bit trying the solution pepeq mentioned here:

    But it didn't work for me.


    What worked is putting "webdav/" after every rewrite statements in the file like this:

    So now my auto rewrites works just fine !


    Hope this solution is helpful to some, and mayby ryecoaaron can tell us if this is bad for omv or the webdav plugin :)

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!