From f77aa316851ff07c18189d19d875df8cd004683a Mon Sep 17 00:00:00 2001 From: Andy Miller Date: Mon, 30 Nov 2020 15:42:01 -0700 Subject: [PATCH] Added scheduler warning --- languages/en.yaml | 1 + themes/grav/templates/partials/tools-scheduler.html.twig | 2 ++ 2 files changed, 3 insertions(+) diff --git a/languages/en.yaml b/languages/en.yaml index a4158c12..39e30028 100644 --- a/languages/en.yaml +++ b/languages/en.yaml @@ -786,6 +786,7 @@ PLUGIN_ADMIN: SCHEDULER_OUTPUT_TYPE_HELP: "Either append to the same file each run, or overwrite the file with each run" SCHEDULER_EMAIL: "Email" SCHEDULER_EMAIL_HELP: "Email to send output to. NOTE: requires output file to be set" + SCHEDULER_WARNING: "The scheduler uses your system's crontab system to execute commands. You should use this only if you are an advanced user and know what you are doing. Misconfiguration or abuse can lead to security vulnerabilities." SECURITY: "Security" XSS_SECURITY: "XSS Security for Content" XSS_WHITELIST_PERMISSIONS: "Whitelist Permissions" diff --git a/themes/grav/templates/partials/tools-scheduler.html.twig b/themes/grav/templates/partials/tools-scheduler.html.twig index 1bf9a4fd..afcc7ed3 100644 --- a/themes/grav/templates/partials/tools-scheduler.html.twig +++ b/themes/grav/templates/partials/tools-scheduler.html.twig @@ -14,6 +14,8 @@
{{ "PLUGIN_ADMIN.SCHEDULER_NOT_ENABLED"|tu }}
{% endif %} +
{{ "PLUGIN_ADMIN.SCHEDULER_WARNING"|tu([user]) }}
+
{{- grav.scheduler.getCronCommand()|trim -}}