Hi @CameronS,
thank you for your feedback and sorry for the late response. You didn’t respond in the thread belonging to this script, so I wasn’t notified right away.
The error message actually indicates that the config directory was not passed on correctly.
The only explanation I can think of is that it has something to do with the rights problems you described.
Yes, it’s true, the script should actually be run completely as root the first time so that the path to the nextcloud installation can be written into the script. That is logged here:
I assume that’s where it went wrong.
Could you please check this output:
grep 'declare $vdirname' /usr/local/bin/nc-who
it should look like this:
declare $vdirname="/var/www/cloud" # <-- don't change this!
If it does not show the path to your nextcloud installation, then run this step again:
and start again from scratch as root:
sudo nc-who
Your feedback provides valuable information that shows me where improvements are still needed.
I wanted to make the script run with unprivileged rights if possible. However, since I have implemented a lot of security features like lock files and such, switching from root to unprivileged is no longer as easy as before. So I still have to make some improvements so that it really works on all systems.
I am sory for that. I will fix that soon, so that log- and lockfiles wil no longer be shared between users and to make it clear, that the first “installation” run must be done as root.
EDIT:
It is fixed now and running
as an unpriviliged user (www-data) should now be possible without any restrictions.
Please test ist.
Much and good luck,
ernolf