gpt4 book ai didi

heroku - 如何将试剂前端部署到 Heroku?

转载 作者:行者123 更新时间:2023-12-05 05:09:41 26 4
gpt4 key购买 nike

我从模板 reagent-frontend 创建了一个 ClojureScript Reagent 应用程序。如何将生产应用程序部署到 Heroku?在为生产构建后(lein package/lein cljsbuild once release)leiningen 在文件夹 public 中生成 app.js。结果公用文件夹包含 css/、js/、index.html。

在我尝试推送文件夹 public Heroku 时给出下一个错误:


! No default language could be detected for this app.

HINT: This occurs when Heroku cannot detect the buildpack to use for this application automatically.

See https://devcenter.heroku.com/articles/buildpacks

! Push failed

最佳答案

Heroku 可以为 PHP 提供服务,因此一种解决方法是添加 index.php使用以下内容公开文件 <?php header( 'Location: /index.html' ) ; ?>这将为您自己的 index.html 提供服务。然后将其推送到 Heroku。

来源:https://blog.teamtreehouse.com/deploy-static-site-heroku

关于heroku - 如何将试剂前端部署到 Heroku?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/57340426/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com