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

how to setup DAV in subdomain? #126

Open
schel4ok opened this issue May 6, 2022 · 0 comments
Open

how to setup DAV in subdomain? #126

schel4ok opened this issue May 6, 2022 · 0 comments

Comments

@schel4ok
Copy link

schel4ok commented May 6, 2022

I want to access dav server at subdomain, but it is not clear how to setup it

in config I have this

'domain' => 'dav',
'path' => '',

In DNS I setup A record dav.mydomain.com pointing to my IP. But I cannot understand how to setup nginx config.

For example I have working config for baikal server. Here root is /var/www/baikal/html. Which root should I use for laravel-sabre? Public folder of laravel doesn't work, because at dav.mydomain.com, I just see laravel homepage, not sabre homepage

server {
    server_name dav.lan baikal.lan dav.mydomain2.com baikal.mydomain2.com;
    root /var/www/baikal/html;
    index index.php;

    rewrite ^/.well-known/caldav /dav.php redirect;
    rewrite ^/.well-known/carddav /dav.php redirect;

    charset utf-8;

    location ~ /(\.ht|Core|Specific|config) {
        deny all;
        return 404;
    }

    location ~ \.php$ {
        try_files $uri =404;
        fastcgi_split_path_info ^(.+\.php)(/.+)$;
        fastcgi_pass php:9000;
        fastcgi_index index.php;
        include fastcgi_params;
        fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
        fastcgi_param PATH_INFO $fastcgi_script_name;
    }
}
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

1 participant