简体   繁体   English

如何将包含后端和前端文件夹的 App 文件夹上传到 Heroku

[英]how to Upload App folder's contain Backend and Frontend folder to Heroku

I created an app called my-book(folder) and this has two folders called my-book-frontend and my-book-backend which are build to React and NodeJS.我创建了一个名为 my-book(folder) 的应用程序,它有两个名为 my-book-frontend 和 my-book-backend 的文件夹,它们是针对 React 和 NodeJS 构建的。

Can anyone help to do, please because I could not understand the procedure how to upload my app folder which has my-book-frontend and my-book-backend.任何人都可以帮忙,因为我不明白如何上传我的应用程序文件夹的过程,它有我的书前端和我的书后端。

I was looking in Internet a long time and I found a way to upload your App in Internet, you need have a account in Vercel.com (is free), and after in your Angular proyect folder write these commands:我在互联网上找了很长时间,我找到了一种在互联网上上传你的应用程序的方法,你需要在 Vercel.com 中拥有一个帐户(免费),然后在你的 Angular proyect 文件夹中写入以下命令:

1- ng build --prod //Generate the dist folder 1- ng build --prod //生成dist文件夹

2- npm install -g now //install the tool 2- npm install -g now //安装工具

3- now //in our directory "dist" 3- 现在 // 在我们的目录“dist”中

4-?Set up and deploy -> Yes 4-?设置和部署 -> 是

5- Introduce our Vercel account 5- 介绍我们的 Vercel 帐户

6-?Link proyect -> No 6-?链接项目 -> 否

7- Set proyect name //Enter, dont write nothing 7-设置项目名称//输入,不要写任何东西

8-?Override settings -> Yes 8-?覆盖设置->是

9- Choose -> Build Command 9-选择->构建命令

And finally you will have a link what finish in.now.sh, oppen this link from any device in the internet explorer and you will have your app in internet.最后,您将获得一个在.now.sh 中完成的链接,从 Internet Explorer 中的任何设备打开此链接,您将在 Internet 上拥有您的应用程序。

PD: in vercel.com you could change DNS, etc. beacause if you have a domain, you could change your url (http:/.....now.sh) for what do you want. PD:在 vercel.com 中,您可以更改 DNS 等,因为如果您有一个域,您可以更改您的 url(http:/.....now.sh)。

This mhettod is tested in Angular 8 and 9 without problems.这个方法在 Angular 8 和 9 中测试没有问题。

This is my first post, i hope it could help many people.这是我的第一篇文章,我希望它可以帮助很多人。

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

相关问题 后端和前端的文件夹结构 - Folder structure for backend and frontend 如何将前端 ReactJs 项目文件夹与 NodeJs 后端连接? - How to connect Frontend ReactJs Project Folder with NodeJs Backend? 如何将 Strapi 后端和 ReactJS 前端部署到单个 Heroku 应用程序 - How to deploy Strapi backend and ReactJS frontend to a single Heroku app 我可以部署一个前端文件夹和后端文件夹都在同一个 Github 存储库上的 MERN 应用程序吗? - Can I deploy a MERN app whose both frontend folder and backend folder are on the same Github repo? 前端和后端组合的应用程序未部署到Heroku - app with combined frontend and backend not deploying to Heroku 在同一个 Heroku 应用程序/dyno 上部署后端和前端 - Deploy the backend and frontend on the same Heroku app/dyno 尝试在后端和前端上传到s3 - Attempt to upload to s3 on backend and frontend 如何将带有 Node 后端的 Svelte 前端部署到 Heroku? - How to deploy Svelte frontend with Node backend to Heroku? 如何在Kubernetes中为Web应用程序创建上传文件夹? - How to create an upload folder for a web app in Kubernetes? 如何从同一个项目文件夹部署ReactJS前端和NodeJS / Express后端? - How to deploy ReactJS frontend and NodeJS/Express backend from the same project folder?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM