Closed WNYmathGuy closed 5 years ago
If you need ro prepend php to run occ, you also need to prepend it on the command
php occ talk:command:add poll Poll 'php /home/ncadmin/domains/cloud.ruppssites.com/public_html/nextcloud/occ talk:poll {ROOM} {USER} "{ARGUMENTS_DOUBLEQUOTE_ESCAPED}"' 2 3
php occ talk:command:add vote Poll 'php /home/ncadmin/domains/cloud.ruppssites.com/public_html/nextcloud/occ talk:poll:vote {ROOM} {USER} "{ARGUMENTS_DOUBLEQUOTE_ESCAPED}"' 2 3
Thanks @nickvergessen ! It seems so obvious now. :man_facepalming:
ncadmin@srv1:~/domains/cloud.ruppssites.com/public_html/nextcloud$ php occ talk:command:add poll Poll 'php /home/ncadmin/domains/cloud.ruppssites.com/public_html/nextcloud/occ talk:poll {ROOM} {USER} "{ARGUMENTS_DOUBLEQUOTE_ESCAPED}"' 2 3
Command added
+----+-----+------+---------+------------------------------------------------------------------------------------------------------------------------------------+----------+---------+
| id | app | name | command | script | response | enabled |
+----+-----+------+---------+------------------------------------------------------------------------------------------------------------------------------------+----------+---------+
| 2 | | Poll | poll | php /home/ncadmin/domains/cloud.ruppssites.com/public_html/nextcloud/occ talk:poll {ROOM} {USER} "{ARGUMENTS_DOUBLEQUOTE_ESCAPED}" | 2 | 3 |
+----+-----+------+---------+------------------------------------------------------------------------------------------------------------------------------------+----------+---------+
If you think your command makes sense for other users as well, feel free to share it in the following github issue:
https://github.com/nextcloud/spreed/issues/1566
I think all my system info you need is at this link: https://cloud.ruppssites.com/index.php/s/fMEsxwkEnWtgE6P/authenticate/showShare and the super secret password is
cGgddmc0dU6lEiiNM1/D
I got to this section:
and usually when I'm told by a Nextcloud developer to do
sudo -u www-data /occ ...
it never works, but if I dophp /occ ...
it does. Thesudo
has an issue when logged in as the Nexcloud virtual server owner.To put another fly in the ointment, I manage my physical server with Virtualmin, and the first set of attempts were logged in as the user for the virtual host that owns Nextcloud, the second set of attempts were as the administrator of the physical server. Below are the terminal outputs: