Heroku忽略公共/资产/清单 - *。json [英] Heroku ignores public/assets/manifest-*.json

查看:156
本文介绍了Heroku忽略公共/资产/清单 - *。json的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在运行 RAILS_ENV =生产捆绑包exec rake assets:precompile 并推送到heroku后,出现此错误:

 运行:rake assets:预编译
rake中止!
无法连接到服务器:连接被拒绝
服务器是否在主机127.0.0.1上运行并接受端口5432上的
TCP / IP连接?

完整的日志在这里: http://dpaste.com/hold/1503531/

当我有一个 public / assets / manifest - *。json 文件已签入?我在使用Rails 4.0.2。



在我的 production.rb 中我有:

  config.assets.compile = false 


解决方案

我解决了这个问题!我添加了一个空的 public / assets / manifest.yml 文件并推送到heroku,并且在推送时不再尝试预编译。

 检测到的manifest.yml,假设资产是在本地编译的


After running RAILS_ENV=production bundle exec rake assets:precompile and pushing to heroku, I get this error:

Running: rake assets:precompile
rake aborted!
could not connect to server: Connection refused
Is the server running on host "127.0.0.1" and accepting
TCP/IP connections on port 5432?

The complete log is here: http://dpaste.com/hold/1503531/

How can this happen when I have a public/assets/manifest-*.json file checked in? I'm using Rails 4.0.2.

In my production.rb I have:

config.assets.compile = false

解决方案

I fixed the issue! I added an empty public/assets/manifest.yml file and pushed to heroku, and it no longer attempted the precompile while pushing.

Detected manifest.yml, assuming assets were compiled locally

这篇关于Heroku忽略公共/资产/清单 - *。json的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆