Hacker News new | ask | show | jobs
by Tloewald 5095 days ago
It seems to me that the kicker is the obviously superior alternatives, such as python, ruby, and JavaScript, don't offer the ease of deployment that php has via mod_php, and instead insist on the developer writing a web server. While there are advantages (performance, control) to the web server approach it is clear that there are advantages (simplicty) to being able to stick code snippets in web pages.

If you could deploy (say) python-decorated web pages via apache (on el cheapo hosting services) versus write yor own server and figure out how to host it then the problem would be solved. We have the languages, just not the ecosystems.

Obviously I'm not the first to observe this. Mod_python exists, it's just not popular.

3 comments

You are wrong to say that these 'insist on the developer writing a web server.' All you have to do is choose a web server, which was also true with PHP (even if all you want to do is choose Apache).

Some of these servers are so easy to install and use, so much EASIER than Apache, that it really gets ridiculous to complain about.

mod_python has been deprecated for years in favor of mod_wsgi, which uses an actual standard. That you don't know this shows that the problem is too much documentation guiding people to things which are no longer modern or standard. If you use Apache, use mod_wsgi, it is infinitely better.

webfaction costs $5.50/mo, lets you do proper Python deploys rather than endless hacks and has good support, if you need cheap Python hosting.

I don't know any rails developer who has written a web server, where did you get that idea? Many use mod_rails via nginx or apache:

http://www.modrails.com/

Also, PAAS offerings like Heroku and Engine Yard make deploying sophisticated rails environments far more convenient than their PHP equivalent.

> "sticking code snippets in web pages"

You can do exactly this in ruby with ERB, but many shy away from this approach due to a distaste for the bolognaise pattern.

You should try ruby/rails/sinatra on your next project, it will change your life.

I've tried rails, years ago. Don't like its fundamental design. My life remains unchanged.

BTW how do you think rails serves web pages?

> If you could deploy (say) python-decorated web pages via apache

This is a terrible, terrible idea. There are a few Python frameworks which have tried similar things, but Model-View-Controller was invented for a reason.