Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

assets_roles ignored #50

Closed
reiz opened this issue Jan 11, 2014 · 3 comments
Closed

assets_roles ignored #50

reiz opened this issue Jan 11, 2014 · 3 comments

Comments

@reiz
Copy link

reiz commented Jan 11, 2014

I'm using this GEMs for my deployment

gem 'capistrano', '3.0.1'
gem 'capistrano-rails', '1.1.0'
gem 'capistrano-bundler', '1.1.1'

In config/deploy/production.rb I defined only 1 single role

role :app, %w{capi@aws-7}

In config/deploy.rb I re defined the assets_roles:

set :assets_roles, [:app]   # Defaults to [:web]

I'm deploying like this:

cap production deploy

And somehow I got always this message and assets:precompile was skipped every time:

WARN [SKIPPING] No Matching Host for bundle exec rake assets:precompile

I could fix it by adding this line to config/deploy/production.rb:

role :web, %w{capi@aws-7}

Somehow this line in my deploy.rb is totally ignored.

set :assets_roles, [:app]   # Defaults to [:web]

Not sure if this is a bug or maybe I misconfigured something.

@rosswilson
Copy link

The options :assets_roles and :assets_prefix shouldn't be shown on the README page because they're not in version 1.1.0. They are only in the master branch.

If you compare the lib/capistrano/tasks/assets.rake file between the master branch and the v1.1.0 tag you'll see the references to :asset_roles and :assets_prefix don't appear in v1.1.0.

In your Gemfile change to using:

gem 'capistrano', github: 'capistrano/capistrano', group: :development
gem 'capistrano-rails', github: 'capistrano/rails', group: :development

And then you'll be using the latest version of Capistrano for Rails, where the above configuration should work.

@kirs
Copy link
Member

kirs commented Jan 15, 2014

I released 1.1.1 version of the gem and you can already use it from Rubygems.

@kirs kirs closed this as completed Jan 15, 2014
@reiz
Copy link
Author

reiz commented Jan 23, 2014

Thanks! Using now version 1.1.1 and it works like expected. 👍

zshannon pushed a commit to zshannon/capistrano-rails that referenced this issue Nov 3, 2015
use release_path instead of current_path
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants