Auto Start NodeJS NPM React App after Reboot using PM2

To auto start node.js npm app after reboot, one way is to use pm2.

First instead pm2:
> npm install -g pm2

Configure pm2 to start as root
> pm2 startup -u root

Add the npm app to pm2 (example shown here is a react app, replace “yourapp” with the name of your react app)
> pm2 start node_modules/react-scripts/scripts/start.js –name “yourapp”

Save the configuration
> pm2 save

Now when you reboot the server, your npm app will be automatically run.

Python 3 & Emacs in Docker

1. Create a dockerfile, e.g., mydockerfile with the following content:

FROM alpine:3.7

Maintainer myhlow

RUN apk upgrade –update && apk add python3 python3-dev gcc gfortran freetype-dev musl-dev libpng-dev g++ lapack-dev emacs
RUN pip3 install –upgrade pip
RUN pip3 install virtualenv
RUN pip3 install numpy scipy pandas scikit-learn

2. Build a local Python 3 with Emacs docker image in the same folder as the dockerfile:

docker build -t python_docker_base -f mydockerfile .

3. Run the docker image:

docker run -it python_docker_base:latest