내 앱이 헤로 쿠에 배포 할 수 있도록 애셋을 사전 컴파일하려고하는데 다음 오류가 발생합니다.레일 레이크 에셋 : 프로덕션 용으로 프리 컴파일
하여 실행하는 경우 :
RAILS_ENV=production bundle exec rake assets:precompile
오류 : 나는 다음과 같은 Gemfile
gem "rails", "~> 3.1.0"
group :production do
gem 'pg'
end
group :development, :test do
gem 'sqlite3'
end
gem 'sass-rails', "~> 3.1.0"
group :assets do
gem 'coffee-rails', "~> 3.1.0"
gem 'uglifier'
gem 'compass', '~> 0.12.alpha.0'
gem 'html5-boilerplate'
end
개발 SQLite는과 생산 PostgreSQL을에 사용하기 때문에 내가 많이 시도했지만
/bin/rake assets:precompile:all RAILS_ENV=production RAILS_GROUPS=assets
rake aborted!
Please install the postgresql adapter: `gem install activerecord-postgresql-adapter` (pg is not part of the bundle. Add it to Gemfile.)
수 ' 이 일을하지 마라.
이 중요하지만 내 database.yml을이처럼 보이는 경우 나도 몰라 :
production:
adapter: postgresql
host: localhost
database: db
encoding: unicode
username: user
password: ''
당신이 삼나무 스택에 이것을 시도 ... 다시 옛 물건을 가지고 죄송합니다
을
:production
그룹실행
bundle
을 제거하는 동안? 'heroku create --stack cedar' – daniel