Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
182 views
in Technique[技术] by (71.8m points)

javascript - Publishing website along with nodejs backend and mysql database

Ok this my sound silly but i have no clue on how to publish node.js backend for website i made. I am new at this and i know how to publish a website there are plenty of websites that offer hosting and domain for some amount of money but i don't know about backend. For example let's say i have node.js backend that reads data from MySQL database and sends it to my local-hosted website. And let's say i have nodemon package installed so i run it with nodemon and everything works fine. My question is how to publish this nodejs app along with my website and database.

question from:https://stackoverflow.com/questions/65894418/publishing-website-along-with-nodejs-backend-and-mysql-database

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

You should get a VPS (Virtual Private Server) with Docker, It is the best solution.

  • Just copy your node folder and put it on a node docker image!
  • Got html front end? Just put it on an nginx docker image.
  • MySQL too, almost everything is possible with docker!

Want to learn more about docker? Here


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...