#๐ How do i host a program somewhere
53 messages ยท Page 1 of 1 (latest)
@odd olive
Remember to:
- Ask your Python question, not if you can ask or if there's an expert who can help.
- Show a code sample as text (rather than a screenshot) and the error message, if you've got one.
- Explain what you expect to happen and what actually happens.
:warning: Do not pip install anything that isn't related to your question, especially if asked to over DMs.
Does it also have HTML at least?
it has no html - it just prints and accepts user input
You need to render and take input from a webpage, i.e. through a HTML template.
Simplest/easiest is to learn Flask/FastAPI and import your script in there with a form to fiill in
GitHub pages won't work for this either, GitHub pages only deals with static pages, if you want to use python then you need a backend
Assuming that this little program doesn't have anything extensive in the backend, it can be frozen to HTML and Javascript so it can run on Github Pages
!pip Frozen-Flask but still have to import it to Flask first
wdym by extensive
and wdym by import to flask
What libraries are you using in your program?
!pip flask is a web app. You have to import your script into the views of Flask so it works as a web app. Then freeze your Flask app with Frozen-Flask so that it works statically for serverless service like Github Pages/Vercel/Netlify etc
Yeah that's not something Github Pages can help
Or any serverless static service
so whats the alternative
You'll have to rent a VPS at least and host your service there
so I can use like google cloud or something?
Yes
AWS/GCP/Azure/Tencent/IBM/etc
Lots of cloud services
I have used www.digitalocean.com for my VPS hosting
is it usually expensive?
You can start really cheap. The cheapest at DigitalOcean is $4 per month
Of course, you get what you paid for. Low specs
But its decent for the price
so with flask, will my program run exactly the same? it currently gets data from github and stores user entries via an api to like jsonbin
Flask just turns your terminal/cli/text-based program into a web app
So its a cosmetic upgrade
and can I do this from google collab?
Google Collab is different
You can do this in google collab for sure but not sure about what you're doing
I know Google Collab can do AI code stuff but not beyond that
Its just an online Jupyter notebook
yea thats what I mean
And no, you can't build Flask stuff in Google Collab
why not
Because it has its own UI
but like if im hosting it on a vps
If you're hosting on a VPS, then do everything in your VPS
Including your own Jupyter notebook
Don't need Google Colab and its throttled GPU
ok thank you!
idk if you need more GPU?
Paperspace has some offers: https://www.paperspace.com/pricing
Paperspace offers a wide selection of low-cost GPU and CPU instances as well as affordable storage options. Browse pricing.
I'm sure you can use other cloud hosted GPU service
This help channel has been closed and it's no longer possible to send messages here. If your question wasn't answered, feel free to create a new post in #1035199133436354600. To maximize your chances of getting a response, check out this guide on asking good questions.