Open MacLemon opened 3 years ago
How do you run your background jobs? Via cron or other? Did you double-check they were running after making the changes?
Your loglevel is too high to log the flow events, IIRC it should be set to 1 for this.
Background jobs are run via cron(8)
have been and are working perfectly fine. There have been no changes to the cron(8)
jobs at all. I've tried loglevels from 3
to 6
. I'll check if setting it to 1
makes any difference.
It seems like cronJob over WebCron calling doesn't run flow scripts, only calling this those, so you need to switch to system cron.
sudo -u www-data php cron.php
Steps to reproduce
Create any shell script you want to trigger with this workflow. eg.
Save it in a location where nextcloud can access it and make it executable.
As nextcloud admin create a new run_script workflow that triggers on pretty much any event.
foo.txt
.foo.txt
touch
the file on a synched client.foo.txt
via Webinterface or sync-clientTest with different regular expressions, make sure to only use lower-case ASCII characters in filenames so we can be sure that nextcloud doesn't trip over any “special characters”.
/^foo\.txt$/i
(as in the example given by the web interface when creating a flow)foo\.txt
(same as above but not case insensitive, though our testfile is explicitly lowercase only)foo.txt
(With.
as a wildcard, no dice)foo.txt
(Explicit and literal exact filename.)foo.*
(to match anything beginning with foo…).*
(Doesn't trigger as well though we'd expect this one to trigger on literally any file since that matches everything.)Expected behaviour
Upon change of a file named
foo.txt
the run_script flow should be triggered and successfully executed.Actual behaviour
Nothing.
Workflow Script app
Workflow Script app version: (see apps admin page:
/index.php/settings/apps
) Multiple Nextcloud 20.0.9.1: Workflow external scripts: 1.5.1 Nextcloud 21.0.1: Workflow external scripts: 1.5.0To be honest, we never go this to work at all since run_script was introduced. So this is not a recent regression from our point of view, it never worked.
Server configuration
Operating system: FreeBSD 12.2-RELEASE-p6 Debian 10 (Buster)
Web server: Apache/Nginx nginx 1.20.0 nginx 1.19.x nginx 1.18.x nginx 1.14.2
Database: MySQL/Maria/SQLite/PostgreSQL MySQL 5.7.33 Postgres 13.2 MariaDB 10.3.27
PHP version: PHP 7.4.18 PHP 7.4.16 PHP 7.3.27-1~deb10u1 PHP 7.3.x PHP 7.2.x
Nextcloud Version: (see admin page) Versions prior to Nextcloud 17 not relevant anymore, but didn't work there as well. 18.x.y 19.x.y 20.0.3-20.0.0 21.0.0-21.0.1
Where did you install Nextcloud from: Debian package FreeBSD package Source
Signing status:
Result on all Instances this was tested on:
No errors have been found.
List of activated apps:
Nextcloud configuration:
Are you using external storage, if yes which one: local/smb/sftp/... Local storage only.
Are you using encryption: yes/no Nextcloud E2EE: No. TLS: Yes
Server log (data/nextcloud.log)
nextcloud.log
doesn't log any events.flow.log
is constantly at0
bytes no matter if flows are triggered (for example the “Automated tagging” flow) orrun_script
doesn't trigger.Additional remarks
I've made sure that the script to be executed is not located within a group folder because of #38.
Testing the flow trigger system with “Automated tagging” does work to auto-add a tag upon change of a file. So we're really certain that all of these nextcloud installations are generally ok and they've been working fine otherwise.
Edit
nextcloud.log
andflow.log
.