diff --git a/src/Handler.php b/src/Handler.php index 6edf1e301a2bd1f6b527f226f94b48d85260a312..ef91f083d6ca729dbfc29ab2148a478cc2091be4 100644 --- a/src/Handler.php +++ b/src/Handler.php @@ -552,9 +552,9 @@ class Handler extends BaseHandler { $disabled = !empty($task['disabled']); $command = $task['command']; $ping_url = FALSE; + $task['name'] = $name; if (isset($hj_manager)) { unset($task['disabled'], $task['command']); - $task['name'] = $name; $task['channels'] = $hj_api_channels; $task['tags'] = implode(' ', ['d4d', $hj_project, $hj_branch]); $task['tz'] = $hj_timezone; diff --git a/templates/crontabs/template.twig b/templates/crontabs/template.twig index 5e66c156fb27368c0106b8f41cbb7b2a3cbae9b0..edc7d5c7cf13153213217ca7bc22ecb22584c7db 100644 --- a/templates/crontabs/template.twig +++ b/templates/crontabs/template.twig @@ -5,6 +5,6 @@ tty = true user = {{ line.user }} schedule = {{ line.schedule }} container = {{ projectname }}-php-1 -command = sh -c \"{{ line.command }}{% if line.ping_url %} && curl -fsS --retry 5 --retry-delay 9 -o /dev/null {{ line.ping_url }}{% endif %}\" +command = sh -c \"{{ line.command|raw }}{% if line.ping_url %} && curl -fsS --retry 5 --retry-delay 9 -o /dev/null {{ line.ping_url }}{% endif %}\" {% endfor %}