Publish the node.js project under Ubuntu to heroku

Use ExpresJS+ReactJS to make a small project, git push to publish to heroku, it is very convenient to do development testing, the following is the publishing process on ubuntu.

About heroku

Heroku is a cloud platform service provider (PaaS) that supports multiple programming languages and is used as a web application deployment model. Heroku is one of the earliest cloud platforms. It has been developed since June 2007. At that time, it only supported the Ruby programming language, but now it supports Java, Node.js, Scala, Clojure, Python, PHP and Go. For this reason, Heroku is considered a multilingual platform because it allows developers to build, run, and extend applications in all languages in a similar way.

Install herokuCLI

$ wget -qO- https://cli-assets.heroku.com/install-ubuntu.sh | sh

Create expressJS project##

$ express myfirstexpress && cd myfirstexpress

If necessary, modify the dependencies of package.json.

Install dependent packages:

$ sudo npm install -l

Initialize git

$ git init
$ git add .
$ git commit -m 'init'

Create heroku project##

$ heroku create myfirstexpress

release##

$ git push heroku master

Run the service (not needed, my project ran directly after pushing it):

$ heroku ps:scale web=1

Check the running status of the service:

$ heroku ps

If there is an error, look at the log:

$ heroku logs

open to take a look:

$ heroku open

Recommended Posts

Publish the node.js project under Ubuntu to heroku
The solution to the failure to install .deb under Ubuntu 16.04
Add a new project to SVN under Ubuntu
How to install Node.js on Ubuntu 16.04
Deploy the mail system under Ubuntu 19.10
How to compile ijkplayer-android under ubuntu
Install nodejs and npm under Ubuntu 16.04
How to install Audacious under Ubuntu
How to install Tensorflow under ubuntu 16.04
How to extend the root directory of LVM under Ubuntu system
ubuntu16.04 method steps to upgrade the kernel
Use mendeley to insert references under ubuntu
Publish ASP.NET Core 2.x application to Ubuntu
Build the C++ compilation environment under ubuntu
Ubuntu modified the default sh to bash
Three ways to install software under Ubuntu
How to change MySQL password under Ubuntu
How to modify the hostname on Ubuntu 20.04
Deploy springboot project through docker under Ubuntu
How to install vim editor under Linux (Ubuntu 18.04)
Expand the disk size of Ubuntu under VMware
Solution for Ubuntu unable to connect to the network
Summary of methods to use Evernote under Ubuntu 14.04
Use rsync to remotely backup data under Ubuntu
Install the old version of seurat under Ubuntu
Use the command to solve the Ubuntu projector problem:
Use doxygen to generate API documentation under Ubuntu 12.04
Wsl sets the default account to root (ubuntu18.04)
Steps to add toolkit for Matlab_Linux under ubuntu
The ultimate guide to install gooderp on ubuntu
Introduction to the use of Hanlp in ubuntu
Mount the disk in a directory under Ubuntu 18.04
How to run the parsing server on Ubuntu 14.04
Solution to pycharm unable to import classes under Ubuntu
How to check the installed JDK on Ubuntu
How to enable Mysql remote access under Ubuntu 14.04
How to install gcc compiler faster under Ubuntu
How to install the latest MySQL on Ubuntu 18.04
How to repackage Deb files under Debian and Ubuntu
Solution to the virtual machine ubuntu16.04 cannot connect to the Internet
Use the command line to detect the Ubuntu version method
How to add the gzip module to Nginx on Ubuntu 14.04
How to turn the language of Ubuntu into Chinese? ?
Solutions to the black screen when installing ubuntu (3 types)
How to install two versions of OpenCV under ubuntu?
Solution to the slow speed of ubuntu18.04 wireless network
How to open https on nginx server under Ubuntu
Resolve the problems encountered in the linux environment under ubuntu