简体   繁体   English

我可以部署一个前端文件夹和后端文件夹都在同一个 Github 存储库上的 MERN 应用程序吗?

[英]Can I deploy a MERN app whose both frontend folder and backend folder are on the same Github repo?

so its my first time deploying an app, I have googled a lot and tried a lot but was not quite able to find the answer.所以这是我第一次部署应用程序,我在谷歌上搜索了很多并尝试了很多,但并没有完全找到答案。 I have a github repo https://github.com/JokubasTolocka/Movie_app which has both frontend and backend folders.我有一个 github 仓库https://github.com/JokubasTolocka/Movie_app ,它有前端和后端文件夹。 During many tries, I have deployed a github page for frontend and everything works as long as I run the backend locally.在多次尝试中,我为前端部署了一个 github 页面,只要我在本地运行后端,一切都可以正常工作。 Whenever I shut down my VScode the github deployments page returns 404 not found.每当我关闭 VScode 时,github 部署页面都会返回 404 not found。 How can I deploy my backend so that I can use this project in my portfolio?我如何部署我的后端以便我可以在我的投资组合中使用这个项目? Any help would be MUCH appreciated!任何帮助将非常感激!

I am also a beginner and was in the same situation, I still want to know how to deploy from the same repo.我也是初学者并且处于相同的情况,我仍然想知道如何从同一个 repo 部署。

I did a quick workaround for my case: I separated both the into different repositories using git subtree command, Check step-by-step instructions here: Detach (move) subdirectory into separate Git repository我为我的案例做了一个快速的解决方法:我使用git subtree命令将它们分成不同的存储库,在此处检查分步说明: 分离(移动)子目录到单独的 Git 存储库

Any further help on this question will be appreciated.对这个问题的任何进一步帮助将不胜感激。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 在同一个 Heroku 应用程序/dyno 上部署后端和前端 - Deploy the backend and frontend on the same Heroku app/dyno 如何从同一个项目文件夹部署ReactJS前端和NodeJS / Express后端? - How to deploy ReactJS frontend and NodeJS/Express backend from the same project folder? 后端和前端的文件夹结构 - Folder structure for backend and frontend 如何将包含后端和前端文件夹的 App 文件夹上传到 Heroku - how to Upload App folder's contain Backend and Frontend folder to Heroku 如何在 GitHub Pages 上部署带有节点后端的 React 应用程序? - How can I deploy a react app with a node backend on GitHub Pages? 如何将我的快递后端和前端反应到 github? - How can I upload both my express backend and react frontend to github? 如何在 MERN 应用程序中调用位于 /src 文件夹之外的节点 indexjs? - How can I call node indexjs which is outside of /src folder in MERN app? 如何将 MERN 堆栈应用程序部署到 GitHub 和 Heroku? - How to deploy MERN stack app to GitHub and Heroku? 我可以将独立的 MERN 应用程序托管/部署为另一个网站的一部分吗? - Can I host/deploy a standalone MERN app as part of another website? 连接前端和后端 MERN 堆栈 - Connecting frontend and backend MERN stack
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM