-
-
Notifications
You must be signed in to change notification settings - Fork 4.1k
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
Server not properly set up to solve well-known/caldav and well-known/carddav after upgrade from 14.0.1 to 14.0.3 #11850
Comments
GitMate.io thinks possibly related issues are #11654 (Some accounts can't log in after upgrade to 14.0.1), #11825 (wrong warnings after upgrade to 14.0.2 (and 14.0.3)), #10920 (After upgrade from 14.0.0 beta 4 to 14.0.0 RC 1: Internal server errors), #11827 (Update from 14.0.1 to 14.0.3 fails), and #11784 (14.0.3). |
Issue looks like it's related to Line 57 in 5daa4f2
Specifically the 301 is set to return "/remote.php/dav" for cardav / caldav, except the function doesn't seem to tack on the base url for the server in the check so it tries to query "/remote.php/dav" instead of "http(s)://domain/remote.php/dav" tacking the domain onto the 301 clear the error, even though the error is erroneous and the check needs to be updated to include the base url. Quick reading it's likely: Line 78 in 5daa4f2
url: <base domain>/url, instead of url: url, like it is now. I'm not familiar enough with this setup to double check how that should get cleared though or I'd make a patch
|
Noting this is what I had, and how it was resolved for me:
What fixed it:
Noting this is in the Apache nextcloud.conf file NOT the .htaccess |
Hi, in the /etc/httpd/conf.d/nextcloud.conf I have only that not Redirect 301...: Alias /nextcloud "/var/www/html/nextcloud/" <Directory /var/www/html/nextcloud/> SetEnv HOME /var/www/html/nextcloud |
Also seen this in 14.0.2 and 14.0.3 even though my /.well-known config hasn't changed for years from the recommended one.
` |
@warthog9 Hey, maybe you can send a PR to the Nextcloud Server repo here on Github with your fix? |
That doesn't make sense, because it includes the hardcoded URL.
Usually fixed in 14.0.2: https://github.com/nextcloud/server/pull/11738/files Also: we fixed the actual check because it never worked before. See also: #11787 (comment) |
@MorrisJobke |
What do you mean with this. The point with this warning is that the initial auto discovery does not work. If the device is already set up using the full URL there is no problem. What does |
I ended up wiping an old iPad for unrelated reasons and needed to setup caldav/carddav again. Here's the curl output:
|
@MorrisJobke Thank you for the curl command, I think I understand now. There's an HAProxy in front of my Nextcloud, and it's doing SSL-offloading. So a fix for me is
|
@cvandesande Thanks! I think this is the solution for me as well. Can not test right now though. Fyi @josh4trunks |
See also nextcloud/documentation#899 for more details about this |
Confirmed, working. Thanks @cvandesande! |
Using the |
@cvandesande's solution for traefik users:
|
I'm having similar issues. I created a thread on the help forums here: https://help.nextcloud.com/t/our-web-server-is-not-properly-set-up-to-resolve-well-known-caldav/56962/2 I've tried changing the nginx conf file but I'm still getting the same basic errors and I don't know why |
Also neither http or https work for me. I'm getting the same errors either way. |
no need for $sheme and $host, I just added this to my config before the
|
For those running Nextcloud behind a reverse proxy (e.g. for TLS offloading), Nextcloud's documentation recommends doing the redirects in the proxy: https://docs.nextcloud.com/server/16/admin_manual/configuration_server/reverse_proxy_configuration.html#service-discovery Example for HAProxy (can be placed either in the backend or the frontend):
|
As posted above #11787 (comment) and with more details http://sabre.io/dav/service-discovery/ tl;dr You're usecase is not supported. The warning will not go away. If you want autodiscover then setup the redirects for example:443/.well-known/caldav (+ the same for carddav) to your nextcloud url including the port, protocol and subfolder. |
@pgnd Have you read #11787 (comment) and http://sabre.io/dav/service-discovery/? Anyway: Example: Cloud is running at According to the sabre most clients will check:
A general note: This is the issue tracker of Nextcloud, please do NOT use this to get answers to your questions or get help for fixing your installation. This is a place to report bugs to developers, after your server has been debugged. You can find help debugging your system on our home user forums: https://help.nextcloud.com or, if you use Nextcloud in a large organization, ask our engineers on https://portal.nextcloud.com. See also https://nextcloud.com/support for support options. |
@pauvos I am trying to do that with traefik v2.0, by any chance, do you have the equivalent config lines for this version ? |
@AntoineMazuyer , no, I use the nextcloud:17.x.x-apache docker image behind traefik 2 and they seem to have fixed it inside the apache conf: $ curl -I https://nextcloud.my.domain/.well-known/caldav
HTTP/2 301
location: https://nextcloud.my.domain/remote.php/dav/
server: Apache/2.4.38 (Debian)
[...] The requests goes through traefik and gets redirected by nextcloud's apache correctly. With traefik 2 I think you have to use routers (https://docs.traefik.io/routing/routers/#rule) to match host and the .well-kown-path, combined with a RedirectRegex middleware (https://docs.traefik.io/middlewares/redirectregex/, https://docs.traefik.io/middlewares/replacepathregex/) or something like that. |
hmmm I still needed to add the redirection manually with a similar configuration. I used that:
|
@AntoineMazuyer - thank you. I tried your solution but I'm still getting the messages: Your web server is not properly set up to resolve "/.well-known/caldav". Further information can be found in the documentation. Was there anything else you did? |
did you also think of including the .well-known/webfinger ? |
I am using nginx with a reverse proxy. This fixed it for me. |
i added the following to my nextcloud ingress:
|
After 4 years, this is what helped me :) Nothing else worked |
@g-vdn I confirm that it is, also for me, the only viable solution. |
This tip did not work for me in nextcloud.conf. I had to change this in the .htaccess file to work properly. Here the configuration is similar. Before:
After:
|
Did you explicitly use example.org in .htaccess? Or is this just a placeholder for your domain? Which would mean nextcloud is sitting behind subfolder of example.org? Because this wouldn't work with a subdomain like cloud.example.org. |
example.org is just a placeholder for my domain. And I am using a subdomain for my instance (nextcloud.example.com). My nextcloud does not sit behind a subfolder of example.org |
After upgrade from 14.0.1 to 14.0.3 I see the following advise:
Your web server is not properly set up to resolve “/.well-known/caldav”.
Your web server is not properly set up to resolve “/.well-known/carddav”.
I see the configuration of well.known/caldav and carddav inside /var/www/html/nextcloud/.htaccess
I tried to change the configuration inserting the complete https of my webserver but without solving.
My configuration centos/postgresql
The text was updated successfully, but these errors were encountered: