From 2758eadff183b554faefe557fe9b9a0641eeba98 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rok=20Andr=C3=A9e?= Date: Thu, 29 Jun 2017 14:51:31 +0200 Subject: [PATCH] Cache must be cleared before it's warmed up See: http://symfony.com/doc/current/deployment.html#d-clear-your-symfony-cache --- recipe/symfony.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/recipe/symfony.php b/recipe/symfony.php index 6ac0ea735..402180f9a 100644 --- a/recipe/symfony.php +++ b/recipe/symfony.php @@ -102,6 +102,12 @@ } })->desc('Dump assets'); +/** + * Clear Cache + */ +task('deploy:cache:clear', function () { + run('{{env_vars}} {{bin/php}} {{bin/console}} cache:clear {{console_options}} --no-debug --no-warmup'); +})->desc('Clear cache'); /** * Warm up cache @@ -134,6 +140,7 @@ 'deploy:vendors', 'deploy:assets:install', 'deploy:assetic:dump', + 'deploy:cache:clear', 'deploy:cache:warmup', 'deploy:writable', 'deploy:symlink',