Slack recipe


Add to Slack

Require slack recipe in your deploy.php file:

require 'recipe/slack.php';

Add hook on deploy:

before('deploy', 'slack:notify');


  • slack_webhook – slack incoming webhook url, required
  • slack_title – the title of application, default {{application}}
  • slack_text – notification message template, markdown supported
    _{{user}}_ deploying `{{branch}}` to *{{target}}*
  • slack_success_text – success template, default:
    Deploy to *{{target}}* successful
  • slack_failure_text – failure template, default:

    Deploy to *{{target}}* failed
  • slack_color – color's attachment
  • slack_success_color – success color's attachment
  • slack_failure_color – failure color's attachment


  • slack:notify – send message to slack
  • slack:notify:success – send success message to slack
  • slack:notify:failure – send failure message to slack


If you want to notify only about beginning of deployment add this line only:

before('deploy', 'slack:notify');

If you want to notify about successful end of deployment add this too:

after('success', 'slack:notify:success');

If you want to notify about failed deployment add this too:

after('deploy:failed', 'slack:notify:failure');