#Bot on replit
1 messages · Page 1 of 1 (latest)
and you also have to change the host and port in settings.json
i got some ips on replit
but i can't access it
which port should I use on the replit?
443 is fine
you can use the repl url
when you start your dashboard or the bot a webview will pop up and there should be a url like https://81b56.....2k.replit.dev/
Where do you put the repl url ?
ok, lets start again
when i import project
i need to change ipc in settings.json
and webapp.py callback url
thats it?
actally im not sure how to host it on repl.it i never tried
but if you want to connect your dashboard to your bot. you have to pass a host and port into ipc_client because by default the ipc_client will connect to 127.0.0.1
to pass the host and port into ipc_client you have to change the code in webapp.py (line 102) ipc_client = IPCClient(host="81b6..f.replit.dev", port=443, secret_key=app.secret_key, callback=message_handler)
when i put repl url
i got this
python ./web/webapp.py
- Serving Flask app 'webapp'
- Debug mode: off
Cannot assign requested address
you have to set the flask host in 0.0.0.0
443 i think
python ./web/webapp.py
- Serving Flask app 'webapp'
- Debug mode: off
WARNING: This is a development server. Do not use it in a production deployment. Use a production WSGI server instead. - Running on all addresses (0.0.0.0)
- Running on http://127.0.0.1:443
- Running on http://172.31.196.37:443
Press CTRL+C to quit
ok now i got some ip adress
but
this is on my repl url
these are not public ip for repl ofc you are not able to access
and if you will to run on port 443 you must use https instead of http
i need to use my custom repl domains?
whats the solution
umm it works for me
after you started the webapp.py
you should get the link that repl provided
how 😦
how you start the dashboard?
when you started the dashboard on repl.it there should be a webview poping up
and then you press on the new tab button in the webview
can you send me your settings.json
ipc_server host and port
webapp.py 211 line
and 23 line
it doesn't required settings.json
socketio.run(app, host="0.0.0.0", port=5000) (line 229)
REDIRECT_URI = 'https://81b56c00-2dd3-4205-825e-e9cd7fd455a1-00-236pcbt5h2v2k.worf.replit.dev/callback' (line 23)
for the REDIRECT_URI you should have your own repl.it public url
i just use the default settings on repl.it
but i will suggestion you to get a real vm instead of using replit
because replit is not stable and not for hosting discord bot
you can get a vps
heroku also not for hosting bot
you can search for vps on google and you will see a lot
ok, thanks