How To Install Node.js on Ubuntu 20.04
cd ~
curl -sL https://deb.nodesource.com/setup_14.x -o nodesource_setup.sh
nano nodesource_setup.sh
sudo bash nodesource_setup.sh
sudo apt install nodejs
node -v
curl -L https://www.npmjs.com/install.sh | sh
npm_config_prefix=/some/path sh install.sh
npm -v
node -v && npm -v
v14.3.0
6.14.4
-
import Google API library (public/index.html): <script src="https://apis.google.com/js/api.js" ></script>
-
initialize Google API library (components/GoogleAuth.js):
componentDidMount() {
window.gapi.load('client:auth2', () => {
window.gapi.client.init({
clientId: '***********-*****************************.apps.googleusercontent.com',
scope: 'email'
}
)
}
)
}
Client run
cd crud-client
npm install
npm start
JSON Server run
cd json-server
npm install
npm start
RTMP Server run
cd rtmp-server
npm install
npm start
OBS Studio install and run
sudo snap install obs-studio
obs-studio
Customize OBS Stream
SETTINGS => Stream
STREAM TYPE => Custom Streaming Server
URL => rtmp://localhost/live
STREAM KEY => 1 (for the stream with ID:1)
STREAM KEY => 2 (for the stream with ID:2)
CLOSE SETTINGS
PRESS THE BUTTON => Start Streaming