我不明白我需要改变什么才能做到这一点。我用app.json和Procfile从这篇博文创建了一个演示项目:
web: fsharpi-heroku WebsahrperSuaveHerokuExample1.sln
接下来,我尝试根据以下建议将其部署到 Heroku:
heroku create websahrper-with-suave-example --buildpack https://github.com/SuaveIO/mono-script-buildpack.git
heroku git:remote -a websahrper-with-suave-example
git push heroku master
构建项目时,Heroku 中存在一个错误:
...
Import process completed.
-----> packages.config found, installing dependencies with nuget
Cannot open assembly 'install': No such file or directory.
! Push rejected, failed to compile SuaveFramework app
如果有解决方案,你能给我一个解决方案吗?
你在这里试过吗:
https://github.com/SuaveIO/heroku-getting-started
分叉它并单击部署到 Heroku 按钮。
没有代表对上述内容发表评论,但只要您没有名为"app.fsx"的文件,Ademar 的解决方案就应该涵盖
heroku 构建包检查是否有脚本,然后检查解决方案:https://github.com/SuaveIO/mono-script-buildpack/blob/master/bin/compile#L66
只需确保项目目录中有一个.sln文件(可以是空的,只需要存在)或分叉构建包,并在编译步骤中将其默认运行mono $YOURPROJECT
。
使用 sln 而不是脚本时,您需要将 Procfile 更改为:
web: mono Path/execName.exe