capistrano-nginx-unicorn icon indicating copy to clipboard operation
capistrano-nginx-unicorn copied to clipboard

unicorn_init.rb missing?

Open oliviermilla opened this issue 10 years ago • 1 comments

Hello, I just inserted your gem in my deploy recipies and I hit a bug. When deploying, I face the following error:

INFO [d7b20958] Running /usr/bin/env sudo service unicorn_white_production restart on xxxxx.net
DEBUG [d7b20958] Command: /usr/bin/env sudo service unicorn_white_production restart
DEBUG [d7b20958]    unicorn_white_production: unrecognized service

now, crawling the code, this comes from unicorn:setup_initializer task which I totally fail to understand since I have no idea where unicorn_init.rb comes from. Any hint?

I use capistrano 3.2.1 + rails 4.1.1 + ruby 2.1.2

oliviermilla avatar May 26 '14 17:05 oliviermilla

Hi @muichkine ,

seems you read the name wrong. The code in unicorn:setup_initializer references unicorn_init.rb.erb which lies under 'lib/generators/capistrano/nginx_unicorn/templates. And it simply is a base unicorn init shell script, which is parsed usingerb` to be capable of understanding ruby variables. Hope, that helps

rockaBe avatar Jun 16 '14 10:06 rockaBe