You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Oct 13, 2021. It is now read-only.
Put all code, install express and ping-monitor, [npm i express ping-monitor]. In bot.js up put this
constkeepAlive=require('./server');constMonitor=require('ping-monitor');keepAlive();constmonitor=newMonitor({website: 'Here your second repl',title: 'Second',interval: 10// minutes});monitor.on('up',(res)=>console.log(`${res.website} its on`));monitor.on('down',(res)=>console.log(`${res.website} down - ${res.statusMessage}`));monitor.on('stop',(website)=>console.log(`${website} stop.`));monitor.on('error',(error)=>console.log(error));
And now create a file with server.js name and put this
constexpress=require('express')constserver=express();server.all('/',(req,res)=>{res.send('The bot is on.');});module.exports=()=>{server.listen(3000,()=>{console.log('Server ready..');});returntrue;}
Well you now create a new repl with name second, and install express and ping monitor and repeat the first step. but in
website: 'repl',
Put the ping monitor repl link and run
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
how to make it online in repl.it?
The text was updated successfully, but these errors were encountered: