在Cedar,Heroku上使用自己的二进制文件 [英] Serve using your own binary on Cedar, Heroku

查看:138
本文介绍了在Cedar,Heroku上使用自己的二进制文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我试图在Heroku上运行Haskell。我编译了一个二进制文件 app 并创建了一个 Procfile ,如下所示:

  web:./app + RTS -N4 

当我将它推到Heroku时,它说:

  -----> Heroku接收推送
! Heroku推送被拒绝,没有Cedar支持的应用程序检测到

现在我认为,Cedar不支持在您的滚动二进制文件。有什么办法可以部署吗?



我已经看过 https ://github.com/mwotton/heroku_haskell_demo 。这个人似乎已经部署到Heroku,但它不再有效。 Heroku看到 Gemfile s,并认为它是一个Ruby应用程序,并运行默认的Procfile,其中 Bundle install 明显失败。

解决方案

您可以将您的Haskell应用程序部署为Node.js.
Cedar栈通过package.json文件的存在将应用程序识别为Node.js。
因此,您应该创建一个package.conf,如下所示:

package.json:

 {name:project-name,version:0.0.1,dependencies:{}} 
pre>

I am trying to run Haskell on Heroku. I have compiled a binary app and created a Procfile as follows:

web: ./app +RTS -N4

When I push it to Heroku, it says:

-----> Heroku receiving push
 !     Heroku push rejected, no Cedar-supported app detected

Now I think, Cedar does not support rolling in your binaries. Is there any way to deploy it?

I have seen https://github.com/mwotton/heroku_haskell_demo. This guy seems to have deployed to Heroku but, it no longer works. Heroku sees the Gemfiles and thinks that it is a Ruby app and runs its default Procfile with Bundle install which fails obviously.

解决方案

You can deploy your Haskell app as Node.js. Cedar stack recognizes an app as Node.js by the existence of a package.json file. So, you should create a package.conf as follows:

package.json:

{ "name": "project-name", "version": "0.0.1", "dependencies": {} }

这篇关于在Cedar,Heroku上使用自己的二进制文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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