Ranter
Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
Comments
-
Hazarth95194yNot sure what your problem was. Im using Flask as well for a service that scrapes a any website for files, downloads them to the backend, zips them up and then lets the user download all of them as a single archive...
All of this in python/Flask, hosted on a remote VPS using WSGI server (Gunicorn in my case) and it works flawlessly.
Bound to localhost:9001 and then routed to 443 via Apache with a Let's Encrypt certificate
Similar setup as you describe, but everything worked pretty much out of the box for me.
:( Sorry to hear you had a bad experience with Flask.
These days I also like to use FastAPI + Vue.js though because of the separation it gives me, but Flask is still nice for something fast -
You couldn't learn Java because of Java 8? I know you said not to ask but... Why?!
-
-
Eklavya17684y@Hazarth Can you provide the documentation or any tutorial you followed to do the same. And, any advice?
-
Hazarth95194y@Eklavya
essentially I just followed this:
https://digitalocean.com/community/...
except when creating the service I use parameter --bind 0.0.0.0:9001
and instead of NginX I have Apache2 with a virtual host on 443 (ssl) and reverse proxy
ProxyPass / http://127.0.0.1:9001/
ProxyPassReverse / http://127.0.0.1:9001
vhost on port 80 just redirects to 443
and I used the Let'sEncrypt installation tool from the official ubuntu repository (sudo apt-get install letsencrypt). This automatically gathered all my apache2 configurations and installed the certificate in them.
after that you just restart Apache2, start the service and everything should work. Now visiting your public IP (or domain URL if you have it linked to that machine) should automatically open up over HTTPS and serve your Flask application (considering you have a landing page on "/", GET) -
hjk10156964yIt's good that you tried many tools and techniques. It will benefit you in the long run. I completely disagree with your conclusion though. I'm afraid it was not the technology but you.
Java 11 is LTS and the latest is 15 (just checked because not a Java dev). Even so Java 8 works too.
I did extremely little with python yet this year I started using it with a buddy because it's a language we have in common. He works on splash so I did all the python stuff with flask. Went quite smooth. Plenty of tutorials. Could copy paste the entire login (including OICD) with some minor adjustments. Runs line a charm on Google app engine for free with TLS.
PHP cannot meet your requirements. Ok I'm primarily a PHP developer. There are some situations it's not ideal for but it's extremely powerful. More powerful than people give it credit for. Had the fastest http implementation until very recently and is still dominating the top 5: https://github.com/the-benchmarker/...
My best guess is that you did not get the right resources. Got a bit stuck and moved on. A lot of JS stuff is relatively fresh and they make it extremely easy to get started. So it's great for some prototyping and get started in web/app development. But please don't forget that the other tools and languages have a lot to offer that JS just doesn't. In my experience it doesn't scale well for example.
Related Rants
My DEV Story
After reading it, make a favor by ++d
Thought to be a software engineer in future
Learnt Python's basic modules, AI, and some ML
After getting intermediate in python, I started learning Java as my second language but could not do it because of JDK 8. Now don't ask me why.
Then, just stepped into game development with unity and C#, having a basic knowledge of C# with no experience in making a game myself. This is called ignorant.
After getting no success, I started learning PHP and got the chance to make a website having no content ;)
But it cannot meet my requirements
Soon I got content that AdSense regards as no content, no problem
I started learning Flask, a module in python for making web applications.
It took me 1 month to complete my website, which can convert file formats.
The idea for deploying it to the server
Sign Up to DigitalOcean
Domain Name from GoDaddy (I know NameCheap is better but got some offer from it)
Made a VPS for what I have to pay $5/month
Deploy my Flask App using WSGI server
This is the worst dev experience
.
.
.
.
Why in all the tutorial, they only deploy a flask app which displays Hello World only and not anything else
WSGI or UWSGI Server does not give us permission to save any file or make any directory in it
Every time........ERROR
Totally Fucked Up
Finally, it works on localhost with port 80
I know this is not the professional way to host a website but this option was only left.
What can I do
Now, I cannot issue a free SSL certificate through Let's Encrypt because **Error 98 Address Already In Used**
The address was port 80 on which my Flask App was running
Check it out now - www.fileconvertex.com
rant
www.fileconvertex.com
dev story