( i have symlink - /www/nextcloud to /srv/www/htdocs/nextcloud)
Error in log
Debug files_texteditor Could not find resource file "/css/files_texteditor/merged.css" 2017-05-23 11:45:07
Error lib ResourceLocator can not find a web root (root: /www/nextcloud/apps/files_texteditor, file: css/files_texteditor/merged.css, webRoot: , throw: true) 2017-05-23 11:45:07
Debug files_sharing Could not find resource file "/css/files_sharing/mergedAdditionalStyles.css" 2017-05-23 11:45:07
Error lib ResourceLocator can not find a web root (root: /www/nextcloud/apps/files_sharing, file: css/files_sharing/mergedAdditionalStyles.css, webRoot: , throw: true) 2017-05-23 11:45:07
Debug files Could not find resource file "/css/files/merged.css" 2017-05-23 11:45:07
Error lib ResourceLocator can not find a web root (root: /www/nextcloud/apps/files, file: css/files/merged.css, webRoot: , throw: true)
CSSResourceLocator.php
append function get param
put to file $root,$file
...
/srv/www/htdocs/nextcloud css/core/server.css
/srv/www/htdocs/nextcloud css/core/share.css
/www/nextcloud/apps/files css/files/merged.css
/www/nextcloud/apps/files_sharing css/files_sharing/mergedAdditionalStyles.css
/www/nextcloud/apps/files_texteditor css/files_texteditor/merged.css
/srv/www/htdocs/nextcloud css/core/systemtags.css
/srv/www/htdocs/nextcloud css/core/server.css
/srv/www/htdocs/nextcloud css/core/share.css
...
I can confirm this issue.
This seems to be biting the Nextcloud snap, as well.
@oparoz can we get this sooner than 13? Otherwise there's no way to update snap users (since they'll need to jump from 11->13, right?).
Ok I shouldn't be changing the labels here but yeah, it'd be nice to have this fixed before Nextcloud 12 so the users of the Box and other Snap users can use Nextcloud 12. May I ask why this was set to enhancement instead of a regression and bug and why only for 13, @oparoz
The same issue was found here: https://github.com/nextcloud/server/issues/4857. I closed it as this one is accepted as bug already 馃挴
I set it as an enhancement, thinking that this was not an officially supported way of using config.php, but let's try to fix the new CSS compiler.
Adding my 2 cents, I have only one symlink at the root of the installation:
root@server:/home/webs/example/cloud# ls -la
total 64
drwxr-x--- 13 www-data www-data 4096 mai 23 22:24 .
drwxr-xr-x 14 www-data www-data 4096 mai 3 2016 ..
drwxr-x--- 5 root root 4096 mai 23 21:36 apps2
drwxr-x--- 14 root root 4096 mai 23 19:06 backups
drwxr-x--- 6 www-data www-data 4096 jan 17 20:07 data
lrwxrwxrwx 1 root root 25 mai 23 19:26 nextcloud -> nextcloud.20170523.12.0.0
drwxr-x--- 14 www-data www-data 4096 jan 17 18:28 nextcloud.20161210.10.0.2
drwxr-x--- 14 www-data www-data 4096 f茅v 1 23:10 nextcloud.20170117.10.0.3
drwxr-x--- 14 www-data www-data 4096 f茅v 1 23:48 nextcloud.20170201.11.0.1
drwxr-x--- 15 www-data www-data 4096 mar 7 00:01 nextcloud.20170228.11.0.2
drwxr-x--- 15 www-data www-data 4096 mai 6 12:00 nextcloud.20170424.11.0.3
drwxr-x--- 14 www-data www-data 4096 mai 23 21:07 nextcloud.20170523.12.0.0
drwxr-x--- 11 www-data www-data 4096 f茅v 1 23:49 nextcloud-data
drwxr-x--- 3 root root 4096 mai 23 18:51 tmp
-rw-r----- 1 root root 1748 mai 23 22:24 update.sh
root@server:/home/webs/example/cloud#
And I have the bad layout on Files and these errors in the logs
...
ResourceLocator can not find a web root (root: /home/webs/example/cloud/nextcloud/apps/files, file: css/files/merged.css, webRoot: , throw: true)
ResourceLocator can not find a web root (root: /home/webs/example/cloud/nextcloud/apps/files_texteditor, file: css/files_texteditor/merged.css, webRoot: , throw: true)
...
In my case, I have no symlinks......
Another use case is the following: let /var/www/nextcloud be a symlink to some external folder. In that case the config.php and apache/ngnix config is "default", but the underlying type is not a folder, but a link. This is what I did and leads to exact the same issue.
In the meantime, is there any workaround, like generate CSS files manually?
I am in the same configuration as @callmemagnus (a symlink to the versionned named folder), and when I tried to mv nextcloud-12.0.0 nextcloud, everything definitely stopped working, because a lot of cache expects to find files in nextcloud-12.0.0.
So this is annoying.
In my case, ~I have no symlinks~, and I also experience this issue, and I would be very grateful for some kind of (even manual) fix, as this bug renders the files app almost unusable, or at least, limits its usability very much. (apart from looking highly unprofessional, file details are missing, sharing options are not accessible, etc..)
I am also finding this in my log:
Debug files_texteditor Could not find resource file "/css/files_texteditor/merged.css" a few seconds ago
Error lib ResourceLocator can not find a web root (root: /var/www/cloud.net/apps/files_texteditor, file: css/files_texteditor/merged.css, webRoot: , throw: true) a few seconds ago
Debug files_sharing Could not find resource file "/css/files_sharing/mergedAdditionalStyles.css" a few seconds ago
Error lib ResourceLocator can not find a web root (root: /var/www/cloud.net/apps/files_sharing, file: css/files_sharing/mergedAdditionalStyles.css, webRoot: , throw: true)

I forgot to mention that I am using the 12.0.0 stable version that is being announces on the official webpage as the version to use. So I would think that such a visible bug should get a swift attention..
Please, let me know what information can I provide to help to fix this problem.
I apologize, I forgot that I had the entire /var/www/ linked to another disk, so when I listed the /var/www/ directory, I didn't see any linked folders. So my case was also caused by using a linked folder in the root directory of the Nextcloud instalation.
Fortunately, getting rid of the link fixed the issue for me.
In case you want to help, I think the change was introduced with #3619.
Thank you for the link @derkostka ! And I apologize again for the misinformation.
I have the same issue, that's my current workaround: https://gist.github.com/sileht/5753118ee048352778c2a0c5b23ea47d
The solution posted by sileht seems to be correct. Could someone merge it?
Done: https://github.com/nextcloud/server/pull/5252. Please consider for 12.0.1. Thanks @sileht again !
@sileht I can't judge the code but if it works, pls consider creating a PR ;-)
I just write a workaround, I don't known if that the "good" solution and I have no time a babysit a PR for this.
But if that the good solution, someone have created a PR here: https://github.com/nextcloud/server/pull/5252
Fixed in 12.0.1 and 13.
@sileht @derkostka thanks a lot for making this happen ;-)
It might be a small patch but we have over 1500 people with a Nextcloud Box at home who can now get 12.0.1 and that's ignoring the many thousands who use the Snap on a normal Ubuntu or other Linux system!
Happens for me for 13.0.2
ResourceLocator can not find a web root (root: /var/lib/nextcloud/apps/tasks, file: css/tasks/3bd5-a778-style.css, webRoot: , throw: true)
@Temtaime it is supposed to be fix, could you open a new issue? :)
Most helpful comment
I have the same issue, that's my current workaround: https://gist.github.com/sileht/5753118ee048352778c2a0c5b23ea47d