Search code examples
symfonydoctrine-ormcapifony

Doctrine migrations with capifony on Jenkins box


I'm trying to deploy an Symfony2 application from a Jenkins box. I'm using capifony multistage deploy system for 2 differents environments: dev and uat.

When I put

before "symfony:cache:warmup", "symfony:doctrine:migrations:migrate"

on my dev.rb file I receive an error from capifony

`symfony:doctrine:migrations:migrate' is only run for servers matching {:roles=>:app, :only=>{:primary=>true}, :except=>{:no_release=>true}}, but no servers matched

How I can deploy and do migrations automatically with capifony?


Solution

  • Fixed!

    In your stage.rb file just add:

    role    :app,               domain, :primary => true