Re: [typo] Deploying Ruby on Rails Applications (was: Re: Can't update feeds?)

2008-07-17 Thread Kevin Williams
On Wed, Jul 16, 2008 at 11:21 PM, Chet Farmer [EMAIL PROTECTED] wrote:
 On Jul 16, 2008, at 7:34 PM, Kevin Williams wrote:
 Let's compare to a Wordpress blog run on Apache using mod_php. The PHP
 code does not serves all requests. Apache serves up the static content
 (css, javascript, graphics, etc.). Many popular front-end servers also
 perform proxying and load balancing, and tons of other functions.
 Mod_php just runs the PHP code. Most Ruby web apps are served in this
 fashion rather than by an Apache module because it was easier to
 implement

 This must be some radical other definition of easier.

At the time Mongrel came around, no one, and I mean no one, would
touch the mod_ruby code. Webrick was slow and FastCGI was very buggy
at best. Zed Shaw stepped up with a strictly-spec-compliant and fast
web server for Ruby. There was much rejoicing and dancing in the
streets. You can call it radical if you want to, but it worked very
well.


 (at the time mod_ruby was a memory-leaking nightmare) and it
 is a more flexible design by virtue of not being tied to Apache and by
 being proxyable behind any decent http proxy.

 It's not a bad idea, it's a sound idea. Please settle down and ask
 polite questions if you truly want to understand and use Typo.

 If you really think I'm the one that needs to settle down, I think you must
 have been reading some other thread.

I politely asked you to change the tone of your requests, yet you
continue to be confrontational. Please stop. Comments such as that's
ridiculous and that's a very bad idea and repeatedly saying you're
wrong when you've clearly shown that you don't understand why things
are the way they are now is just causing trouble. You have issues with
Typo and want help. Is this really how you ask for help?


 I've made it abundantly clear that I am 100% uninterested in installation
 tweaks right now because I am dealing with bugs in Typo. That's my
  front-burner issue. If these bugs can't get resolved, the installation
 issues are irrelevant. I appreciate you explaining the rationale for
 Mongrel, et. al., above, nevertheless.

You're welcome, and thank you for saying so.
___
Typo-list mailing list
Typo-list@rubyforge.org
http://rubyforge.org/mailman/listinfo/typo-list


Re: [typo] Deploying Ruby on Rails Applications (was: Re: Can't update feeds?)

2008-07-17 Thread Chet Farmer


On Jul 17, 2008, at 10:02 AM, Kevin Williams wrote:

At the time Mongrel came around, no one, and I mean no one, would
touch the mod_ruby code. Webrick was slow and FastCGI was very buggy
at best. Zed Shaw stepped up with a strictly-spec-compliant and fast
web server for Ruby. There was much rejoicing and dancing in the
streets. You can call it radical if you want to, but it worked very
well.


I appreciate you giving the backstory here, but having to include  
another web server, though, is not something I'd describe as easier  
when compared to other tools that require only one.



Please settle down and ask
polite questions if you truly want to understand and use Typo.


If you really think I'm the one that needs to settle down, I think  
you must

have been reading some other thread.


I politely asked you to change the tone of your requests, yet you
continue to be confrontational.


I was confrontational to Scott because his posts were snide, rude,  
useless knee-jerk defenses of his pet stack.



Please stop. Comments such as that's
ridiculous and that's a very bad idea and repeatedly saying you're
wrong when you've clearly shown that you don't understand why things
are the way they are now is just causing trouble.


My complaints really began with this very point; recall one of my  
original points was the poor state of documentation concerning the  
idiosyncratic installation requirements of Typo.


If it were more clear why I should consider installing another web  
server just to run Typo from Typo's own docs, perhaps I wouldn't be  
complaining about the docs.



You have issues with
Typo and want help. Is this really how you ask for help?


I certainly wasn't asking Scott for help, and he certainly wasn't  
providing any. He jumped in to tell me my assessment of the state of  
Ruby/Rails/Typo installation was wrong, which is simply incorrect.  
He's offered nothing of value to me in re: my actual problems.


My original posts to this list met with either no response at all, or,  
more recently, helpful responses from Frederic. Frankly, I was  
surprised, after that, to get Scott's fanboy eruptions. I believe I  
dealt with him appropriately, and with a level of grace appropriate  
for handling such a poster.




Chet
-
Life has improved immeasurably since I have been forced  to stop  
taking it seriously.  Hunter S. Thompson



___
Typo-list mailing list
Typo-list@rubyforge.org
http://rubyforge.org/mailman/listinfo/typo-list


Re: [typo] Deploying Ruby on Rails Applications (was: Re: Can't update feeds?)

2008-07-17 Thread Scott Likens


On Jul 17, 2008, at 11:36 AM, Chet Farmer wrote:
My complaints really began with this very point; recall one of my  
original points was the poor state of documentation concerning the  
idiosyncratic installation requirements of Typo.


If it were more clear why I should consider installing another web  
server just to run Typo from Typo's own docs, perhaps I wouldn't be  
complaining about the docs.



You have issues with
Typo and want help. Is this really how you ask for help?


I certainly wasn't asking Scott for help, and he certainly wasn't  
providing any. He jumped in to tell me my assessment of the state of  
Ruby/Rails/Typo installation was wrong, which is simply incorrect.  
He's offered nothing of value to me in re: my actual problems.


My original posts to this list met with either no response at all,  
or, more recently, helpful responses from Frederic. Frankly, I was  
surprised, after that, to get Scott's fanboy eruptions. I believe I  
dealt with him appropriately, and with a level of grace appropriate  
for handling such a poster.


Perhaps you mistook my emails as a knee-jerk nonsense emails.  But I  
was trying to get more information to provide some assistance, however  
I was not getting any valid feedback.  I realize I did not word them  
in a way that you wanted, however my intent was to get more  
information to help.


I searched through old emails trying to find any information of why  
you could not do this or that, and Truthfully all I could find were  
posts related to MarsEdit.  Which those bugs have been fixed in  
trunk, if you want you can try updating to Trunk and see if that  
fixes your problems?



___
Typo-list mailing list
Typo-list@rubyforge.org
http://rubyforge.org/mailman/listinfo/typo-list


Re: [typo] Deploying Ruby on Rails Applications (was: Re: Can't update feeds?)

2008-07-17 Thread de Villamil Frédéric

Le 17 juil. 08 à 22:30, Scott Likens a écrit :



On Jul 17, 2008, at 11:36 AM, Chet Farmer wrote:
My complaints really began with this very point; recall one of my  
original points was the poor state of documentation concerning the  
idiosyncratic installation requirements of Typo.


If it were more clear why I should consider installing another web  
server just to run Typo from Typo's own docs, perhaps I wouldn't be  
complaining about the docs.



You have issues with
Typo and want help. Is this really how you ask for help?


I certainly wasn't asking Scott for help, and he certainly wasn't  
providing any. He jumped in to tell me my assessment of the state  
of Ruby/Rails/Typo installation was wrong, which is simply  
incorrect. He's offered nothing of value to me in re: my actual  
problems.


My original posts to this list met with either no response at all,  
or, more recently, helpful responses from Frederic. Frankly, I was  
surprised, after that, to get Scott's fanboy eruptions. I believe I  
dealt with him appropriately, and with a level of grace appropriate  
for handling such a poster.


Perhaps you mistook my emails as a knee-jerk nonsense emails.  But I  
was trying to get more information to provide some assistance,  
however I was not getting any valid feedback.  I realize I did not  
word them in a way that you wanted, however my intent was to get  
more information to help.


I searched through old emails trying to find any information of why  
you could not do this or that, and Truthfully all I could find were  
posts related to MarsEdit.  Which those bugs have been fixed in  
trunk, if you want you can try updating to Trunk and see if that  
fixes your problems?



I've fixed MetaWeblog API tags issues as well in trunk today. However,  
it seems marsedit doesn't support that feature (or didn't found how to  
do so). Other issue for me is that the Metaweblog API provides a  
getCategories method, but no way to getKeywords, which means 2 things :
– Using the metaweblog API won't let you see which tags already exist  
on your blog (our wb based admin interface now have tags autocompletion)
– Editing a post will make you delete every tags used so far from this  
post, unless you remember them and add them by hand.


Regarding the documentation, I've been talking with a friend today  
about what we should provide. Cool things came up, and amongst them  
the fact we should officially support one installation way of self  
hosting Typo, which means the easiest one (obvious heh ?). Having to  
choose between 3 webservers, and 3 ways to serve pages (mod_rails,  
(Fast)CGI and application server) is just too confusing for people. If  
they want to deploy their webserver an exotic way (that's to say  
without Apache + MySQL which are the most widespread things you've  
ever found on the Internet), it's not our problem. However, we'll keep  
the existing docs about exotic configs for information purpose.  
redmine.typosphere.org is a wiki, if someone want to complete... it's  
up to him / her.


Was my 2 cents, now I must leave you, I've a release t finish before  
sunday and I'd love to add some more fancy things if I can (like  
autosave). If anyone want to help instead of just trolling :-)

--
Frédéric de Villamil
[EMAIL PROTECTED]tel: +33 (0)6 62 19 1337
http://fredericdevillamil.com Typo : http://typosphere.org

___
Typo-list mailing list
Typo-list@rubyforge.org
http://rubyforge.org/mailman/listinfo/typo-list


Re: [typo] Deploying Ruby on Rails Applications (was: Re: Can't update feeds?)

2008-07-16 Thread Chet Farmer


Look. I like Typo. I'm still trying to use it. But mails like this  
just tick me off. They provide no help to speak of while insisting  
there is no problem.


Also, proofreading is a good idea.

On Jul 15, 2008, at 10:22 PM, Scott Likens wrote:

To whomever it may concern,


I reckon that would be me, among others.


I notice the common thread here.  How to deploy typo?


Why do you think that is?

The choices are:

a) Typo IS hard to deploy; or
b) Typo isn't hard to deploy, but is poorly documented; or
c) Typo isn't hard to deploy, and is well documented, but the  
documentation is hard to find; or

d) The people posting this question are all idiots.

Hint: It isn't (d), and (a), (b), and (c) are functionally identical.


There is many ways to deploy typo, the most common is

1) FastCGI.  (It's also the most murky confusing documentation imo,  
I don't blame this on typo, I blame this on FastCGI Documentation  
and the people who wrote it).

2) Mongrel/Webrick
3) Phusion Passenger (aka mod_rails?)

Now, there's no real difference with Mongrel/Webrick if you run  
nginx or Apache or lighttpd.  It works, it's well documented and  
takes the most amount of memory (actually all of them really take  
the same amount of memory, you just don't see the ruby process  
hanging around using up 140megs of memory).


Um, no. It is NOT well documented, or, if it is, those documents are  
not easy to find. They're not complete at Typosphere, and they're not  
apparent anywhere else I looked. I saw rote, by-the-numbers list dox,  
but nothing that explained why I was doing what it said to do, or what  
the rationale  was behind Mongrel vs. mod_ruby, or anything an admin  
will want to know when making the choices that are part of an  
installation. If those docs exist and I somehow missed them, I will  
GLEEFULLY accept pointers.


 Phusion Passenger... Excellent option, if you have a cheap  
Dreamhost.com account that is going to be your easiest option,  
documentation is decent and it's much easier to deploy.


First I've heard of it. Maybe it's a great choice; I have no idea. I  
wish I'd known about it when I first started playing with Typo.



So there you have it, 3 basic methods to deploy your blog.


You say this as though your post constitutes instructions. This is not  
the case.


If your coding Ruby on Rails chances are this is nothing new to you,  
and you have no problem with it.  But those who have come from the  
PHP Boat (as we'll call it, a/k/a wordpress, etc) they just untar  
files into a directory edit a few files, loadup their web browser  
and bam.  It works.


Yup. Nice, too. This is, above perhaps all else, why a bad language  
(PHP) has earned such a dominant market position.


This is because the company behind PHP has spent a great deal of  
time and money at making PHP the dominant language.


Er, and PHP itself, or  mod_php, or whatever, pretty much Just Works  
without installing half a dozen more components, proxies, etc. This  
ease of use took effort, it's true, but it also provides nontrivial  
value.


It doesn't make it better, or worse or anything.  (It scales  
horribly also for those of you who are talking about scaling).


Actually, easy to deploy DOES earn an app significant points with  
pretty much any administrator I know. I consider that better.


Let's say you grab a Perl based blog, what's your common problem?   
Well mod_perl, perl with ithreads enabled.  Yeah you can use it as a  
cgi script and have it exec perl on each page/function.  But again,  
we'll go with it does not scale well.  We have Python and django, I  
know have not touched any of the django software really so I won't  
go there.


Do you have a point here?


So let's bust out some simple myths,

Rails is hard to deploy, FALSE.  In fact Ruby on Rails Applications  
are quite easy to deploy provided your hosting company gives you an  
environment where it can deploy sanely.


Is this a synonym for provided your hoster does it for you? Because  
I've installed Rails on several different *nixes over the years, and  
have *never* found it to be simple to get running in a production  
environment (i.e., ignoring quickie dev stacks like Locomotive).


 This is something that DHH has commented on a few times; there is  
no way to make the pain of deploying a Ruby on Rails app on a bad/ 
cheap hosting server go away.  Is that the fault of Ruby on Rails?  
or the company you chose to host with?  I'll let you decide on that  
one.


If application stack A installs quickly and cleanly, and  
application stack DHH doesn't, do I care? I'll let you decide on  
that one.


Shared hosting does not equal bad hosting. It's totally appropriate  
for probably 85-95% of the blogs that exist. Being essentially  
incompatible with shared hosting environments is a bad move for Rails,  
and DHH saying otherwise doesn't make it so. Being hard to get running  
in a hosted environment makes Ruby on Rails less appealing, and  

Re: [typo] Deploying Ruby on Rails Applications (was: Re: Can't update feeds?)

2008-07-16 Thread Scott Likens

Chet,

Which portion of the documentation needs to be revised? FastCGI?  
Mongrel? I suppose someone can whip up some instructions on how to  
make the config.ru for Passenger if need be.  Typo is imo extremely  
easy to deploy and get up in running in under 5 minutes.  If your  
having a problem deploying typo please elaborate and tell us what the  
problem is with you deploying Typo so we can help you deploy it?  I  
can read over old e-mails however that does not always constitute the  
current situation.  Specifics are excellent, like are you using Apache  
2.0? 2.2? 1.3?  How are you attempting to deploy it via FastCGI?  
Mongrel?


As far as Phusion Passenger (http://www.modrails.com/) it's actually  
if you look at their site they even have tested Typo with it (http://www.modrails.com/documentation.html 
).


Ideally, one would like to use Swiftiply (Mongrel with some added  
performance), but that's not here nor there.


In typo 4.1.1 (I won't reference a recent version because I don't have  
one installed currently) there is typo/installer and inside there is  
examples for apache13 apache20 (which works for 22) and lighttpd  
(fastcgi).  For the most part you should just have to Copy  Paste,  
modify the small things and go.


But I will leave the question open here,

How can we help you deploy Typo? be as specific as possible.



On Jul 15, 2008, at 11:24 PM, Chet Farmer wrote:



Look. I like Typo. I'm still trying to use it. But mails like this  
just tick me off. They provide no help to speak of while insisting  
there is no problem.


Also, proofreading is a good idea.

On Jul 15, 2008, at 10:22 PM, Scott Likens wrote:

To whomever it may concern,


I reckon that would be me, among others.


I notice the common thread here.  How to deploy typo?


Why do you think that is?

The choices are:

a) Typo IS hard to deploy; or
b) Typo isn't hard to deploy, but is poorly documented; or
c) Typo isn't hard to deploy, and is well documented, but the  
documentation is hard to find; or

d) The people posting this question are all idiots.

Hint: It isn't (d), and (a), (b), and (c) are functionally identical.


There is many ways to deploy typo, the most common is

1) FastCGI.  (It's also the most murky confusing documentation imo,  
I don't blame this on typo, I blame this on FastCGI Documentation  
and the people who wrote it).

2) Mongrel/Webrick
3) Phusion Passenger (aka mod_rails?)

Now, there's no real difference with Mongrel/Webrick if you run  
nginx or Apache or lighttpd.  It works, it's well documented and  
takes the most amount of memory (actually all of them really take  
the same amount of memory, you just don't see the ruby process  
hanging around using up 140megs of memory).


Um, no. It is NOT well documented, or, if it is, those documents are  
not easy to find. They're not complete at Typosphere, and they're  
not apparent anywhere else I looked. I saw rote, by-the-numbers list  
dox, but nothing that explained why I was doing what it said to do,  
or what the rationale  was behind Mongrel vs. mod_ruby, or anything  
an admin will want to know when making the choices that are part of  
an installation. If those docs exist and I somehow missed them, I  
will GLEEFULLY accept pointers.


Phusion Passenger... Excellent option, if you have a cheap  
Dreamhost.com account that is going to be your easiest option,  
documentation is decent and it's much easier to deploy.


First I've heard of it. Maybe it's a great choice; I have no idea. I  
wish I'd known about it when I first started playing with Typo.



So there you have it, 3 basic methods to deploy your blog.


You say this as though your post constitutes instructions. This is  
not the case.


If your coding Ruby on Rails chances are this is nothing new to  
you, and you have no problem with it.  But those who have come from  
the PHP Boat (as we'll call it, a/k/a wordpress, etc) they just  
untar files into a directory edit a few files, loadup their web  
browser and bam.  It works.


Yup. Nice, too. This is, above perhaps all else, why a bad  
language (PHP) has earned such a dominant market position.


This is because the company behind PHP has spent a great deal of  
time and money at making PHP the dominant language.


Er, and PHP itself, or  mod_php, or whatever, pretty much Just Works  
without installing half a dozen more components, proxies, etc. This  
ease of use took effort, it's true, but it also provides nontrivial  
value.


It doesn't make it better, or worse or anything.  (It scales  
horribly also for those of you who are talking about scaling).


Actually, easy to deploy DOES earn an app significant points with  
pretty much any administrator I know. I consider that better.


Let's say you grab a Perl based blog, what's your common problem?   
Well mod_perl, perl with ithreads enabled.  Yeah you can use it as  
a cgi script and have it exec perl on each page/function.  But  
again, we'll go with it does not scale 

Re: [typo] Deploying Ruby on Rails Applications (was: Re: Can't update feeds?)

2008-07-16 Thread Chet Farmer


On Jul 16, 2008, at 6:04 AM, Scott Likens wrote:
Which portion of the documentation needs to be revised? FastCGI?  
Mongrel?


Honestly, all of it. I know that's a broad answer, but it's the truth.  
Compare the installation experience of a LAMP stack tool to Typo's and  
you'll see the huge gap.


In particular, deeper descriptions of why Mongrel needs to be  
involved, what the alternatives to a Mongrel configuration are, and  
why one might choose one approach over the other are ALL questions  
that need to be addressed. I made that clear in my prior post.


Typo is imo extremely easy to deploy and get up in running in under  
5 minutes.


Here, you're just plain wrong.

 If your having a problem deploying typo please elaborate and tell  
us what the problem is with you deploying Typo so we can help you  
deploy it?


I had problems getting mine to run, that's certainly true. But at this  
point my Typo runs (just not in the way I really want it do; the  
machine can't also run Apache -- as, again, I've made clear before).


My issues are bugs in Typo. If I can't get those bugs resolved, Typo's  
quirky and difficult installation issues will become academic, as I'll  
have to migrate to something else. The important bugs to ME are:


-- my feeds do not dynamically update. They get created when first  
requested, but are then frozen in amber.


-- Typo does not work properly with MarsEdit or other stand-alone  
editors. This is a show-stopper for me. 

I also have some other outstanding questions regarding updating my  
Typo, and verifying the version I have, but those are in another mail  
I posted early yesterday, I believe, and are part of a dialog with  
Frederic.


- How do I verify what version of Typo I have?
- How is it best to upgrade Typo? What specific steps should be taken,  
and why?



---
They say no mortal woman was enough for him so he made one himself  
outta whiskey an liquors an ale, says me. An he loved her like a  
lumberjack made of eating loves a woman made of ham. (Fafblog  
2004-08-05)


___
Typo-list mailing list
Typo-list@rubyforge.org
http://rubyforge.org/mailman/listinfo/typo-list


Re: [typo] Deploying Ruby on Rails Applications (was: Re: Can't update feeds?)

2008-07-16 Thread Scott Likens


On Jul 16, 2008, at 6:43 AM, Chet Farmer wrote:



On Jul 16, 2008, at 6:04 AM, Scott Likens wrote:
Which portion of the documentation needs to be revised? FastCGI?  
Mongrel?


Honestly, all of it. I know that's a broad answer, but it's the  
truth. Compare the installation experience of a LAMP stack tool to  
Typo's and you'll see the huge gap.


In particular, deeper descriptions of why Mongrel needs to be  
involved, what the alternatives to a Mongrel configuration are, and  
why one might choose one approach over the other are ALL questions  
that need to be addressed. I made that clear in my prior post.


We are comparing an Apple to a Pear, LAMP is not the same as LAMR or a  
Ruby on Rails install.  Please stop comparing it, you are doing  
nothing useful by doing that.


What is mongrel? Let's see here if this quote satisfy's you.

Mongrel is a small library that provides a very fast HTTP 1.1 server  
for Ruby web applications. It is not particular to any framework, and  
is intended to be just enough to get a web application running behind  
a more complete and robust web server.


What makes Mongrel so fast is the careful use of an Ragel extension to  
provide fast, accurate HTTP 1.1 protocol parsing. This makes the  
server scream without too many portability issues.


See mongrel.rubyforge.org for more information. 

A bit technical, but Mongrel is a Web Server.  Like Apache, or nginx  
or lighttpd.  Except that all it cares about and knows about is the  
application in which it is running.  Technically you can run it on  
port 80 (if you run it as root) and remove the whole extra web server  
from the equation.  Mongrel is for Ruby what mod_php is for Rails (bad  
analogy).  It does all the dirty work and forwards the end product to  
Apache and then to the end-user.  You can compare it to Tomcat or  
Jetty I guess, however that's not here nor there.


Typo is imo extremely easy to deploy and get up in running in under  
5 minutes.


Here, you're just plain wrong.

If your having a problem deploying typo please elaborate and tell  
us what the problem is with you deploying Typo so we can help you  
deploy it?


I had problems getting mine to run, that's certainly true. But at  
this point my Typo runs (just not in the way I really want it do;  
the machine can't also run Apache -- as, again, I've made clear  
before).


My issues are bugs in Typo. If I can't get those bugs resolved,  
Typo's quirky and difficult installation issues will become  
academic, as I'll have to migrate to something else. The important  
bugs to ME are:


-- my feeds do not dynamically update. They get created when first  
requested, but are then frozen in amber.


-- Typo does not work properly with MarsEdit or other stand-alone  
editors. This is a show-stopper for me.
I also have some other outstanding questions regarding updating my  
Typo, and verifying the version I have, but those are in another  
mail I posted early yesterday, I believe, and are part of a dialog  
with Frederic.


- How do I verify what version of Typo I have?
- How is it best to upgrade Typo? What specific steps should be  
taken, and why?



Frédéric has pretty much gone into the other problems you addressed.

However, the best method of updating/upgrading typo depends on the  
backend.


Let's say you use SQLite3

1) backup your databases in db/ to a separate location
2) unarchive the new version of typo in a separate directory (for  
staging or testing purposes).
3) copy the backed up databases (do not move them, we want to keep a  
pristine copy still somewhere) to db/
4) verify you are using the proper environment (e.g. PRODUCTION /  
DEVELOPMENT ...) and then run rake db:migrate

5) start typo on a different port then the original typo is running on.
6) Browse to the site by ip:port and verify if everything worked as  
planned, and if it did not discuss how it did not work properly, and  
if it did work how it can work easier.


... Now let's say you use MySQL.

1) mysqldump your typo database for backup purposes.
2) mysqlhotcopy -u root -p typo typo2
3) fixup the grants if need be so your typo login can see typo2 (if  
you use the root account for typo you can skip this step)
4) unarchive the new version of typo, and setup database.yml to see  
typo2 and the proper credentials and settings.

5) rake db:migrate
6) start typo on a different port and test it out.

Of course you'll have to reinstall your plugins and themes.  I believe  
as a standard practice it's best to set the theme to default and  
disable your plugins before you do the backup.  I don't know if  
Frédéric has resolved the technical details of plugins missing and  
themes missing and having to goto the admin interface and fix it, or  
delve into the MySQL database and disable plugins that way.


But that's a pretty short write-up.

___
Typo-list mailing list
Typo-list@rubyforge.org

Re: [typo] Deploying Ruby on Rails Applications (was: Re: Can't update feeds?)

2008-07-16 Thread Chet Farmer


On Jul 16, 2008, at 5:38 PM, Scott Likens wrote:
Honestly, all of it. I know that's a broad answer, but it's the  
truth. Compare the installation experience of a LAMP stack tool to  
Typo's and you'll see the huge gap.


In particular, deeper descriptions of why Mongrel needs to be  
involved, what the alternatives to a Mongrel configuration are, and  
why one might choose one approach over the other are ALL questions  
that need to be addressed. I made that clear in my prior post.


We are comparing an Apple to a Pear, LAMP is not the same as LAMR or  
a Ruby on Rails install.  Please stop comparing it, you are doing  
nothing useful by doing that.


Are you really saying you can't compare a Ruby app with a LAMP app?  
That's ridiculous. How else can someone decide between Typo and MT and  
WP and etc?


No, you're just wrong. It makes PERFECT sense to compare the  
experience of setting up and using Application X with that of using  
Application Y if both X and Y are competitors in the same market  
(i.e., blogging software).



What is mongrel? Let's see here if this quote satisfy's you.

Mongrel is a small library that provides a very fast HTTP 1.1  
server for Ruby web applications. It is not particular to any  
framework, and is intended to be just enough to get a web  
application running behind a more complete and robust web server.


What makes Mongrel so fast is the careful use of an Ragel extension  
to provide fast, accurate HTTP 1.1 protocol parsing. This makes the  
server scream without too many portability issues.


See mongrel.rubyforge.org for more information. 

A bit technical, but Mongrel is a Web Server.  Like Apache, or nginx  
or lighttpd.  Except that all it cares about and knows about is the  
application in which it is running.  Technically you can run it on  
port 80 (if you run it as root) and remove the whole extra web  
server from the equation.  Mongrel is for Ruby what mod_php is for  
Rails (bad analogy).  It does all the dirty work and forwards the  
end product to Apache and then to the end-user.  You can compare it  
to Tomcat or Jetty I guess, however that's not here nor there.


Why on earth would you need to run a second web server? That seems  
like a really bad idea, frankly, hence my annoyance that the most  
obvious question (which boils down to WTF?, essentially)  isn't  
addressed.



Frédéric has pretty much gone into the other problems you addressed.

However, the best method of updating/upgrading typo depends on the  
backend.


Let's say you use SQLite3

1) backup your databases in db/ to a separate location
2) unarchive the new version of typo in a separate directory (for  
staging or testing purposes).
3) copy the backed up databases (do not move them, we want to keep a  
pristine copy still somewhere) to db/
4) verify you are using the proper environment (e.g. PRODUCTION /  
DEVELOPMENT ...) and then run rake db:migrate


What does rake do in this context?

5) start typo on a different port then the original typo is running  
on.
6) Browse to the site by ip:port and verify if everything worked as  
planned, and if it did not discuss how it did not work properly, and  
if it did work how it can work easier.


Of course you'll have to reinstall your plugins and themes.




To put it mildly, that's a bit bizarre and very unfriendly to the user.


I believe as a standard practice


Maybe for Typo. Not for anything else I use.

Chet Farmer

When you've got an RV, a jet pack, and a monkey you really don't need  
much actual content  - KS





___
Typo-list mailing list
Typo-list@rubyforge.org
http://rubyforge.org/mailman/listinfo/typo-list


Re: [typo] Deploying Ruby on Rails Applications (was: Re: Can't update feeds?)

2008-07-16 Thread JZ
On Wed, Jul 16, 2008 at 4:22 AM, Scott Likens [EMAIL PROTECTED] wrote:

 To whomever it may concern,
 I notice the common thread here.  How to deploy typo?

 There is many ways to deploy typo, the most common is
 1) FastCGI.

We all know, it sucks.

 2) Mongrel/Webrick

Nginx with proxy load balancer to cluster of Thin/Ebb (+unix socket)
processes is a much faster.

 3) Phusion Passenger (aka mod_rails?)

This is the best option. Fast and dead brain simple to deploy (just like PHP).

 Now, there's no real difference with Mongrel/Webrick

Mongrel is much faster than Webrick. Thin is faster than Mongrel, and
Ebb is faster than Mongrel or Thin.

  But those who have come from the PHP Boat (as we'll call
 it, a/k/a wordpress, etc) they just untar files into a directory edit a few
 files, loadup their web browser and bam.  It works.

Phusion mod_passenger  (http://www.modrails.com/) works in the very
same way. Just copy your files, load web browser and bam. It works.
Need to reload application? No problem. Create empty restart.txt file
in the tmp folder. Apache will reload the application. No need to
restart Apache. No SSH needed. Simple FTP access is all you need.
mod_passenger works also with others  Ruby frameworks which use
Rack,e.g. Merb. It even works also with Python... :)

You also forget mention Ruby Enterprise version which uses 33% less
memory... It works fine with mod_passenger and lowers the memory
footprint. http://www.rubyenterpriseedition.com/

mod_passenger is _the easiest option_  for deployment Rails
applications (including Typo).

But, there is also another, 4-th deploy option: JRuby. It is also
brain dead simple to deploy. Just create WAR file and copy it into
webapps Tomcat's folder. That's all!

sudo jruby -S gem install warbler, activerecord-jdbc-adapter
jruby -S rails my_app

For developing use: jruby script/server; jruby script/console etc.

For production, just create  ROOT.war file (with warble war command)
and copy it into webapps folder in Tomcat, Jetty or another Java
servlets container. This WAR file contains ALL gems (including JRuby
interpreter) so it works fine in all platforms.

-- 
Jaroslaw Zabiello
http://blog.zabiello.com
___
Typo-list mailing list
Typo-list@rubyforge.org
http://rubyforge.org/mailman/listinfo/typo-list


Re: [typo] Deploying Ruby on Rails Applications (was: Re: Can't update feeds?)

2008-07-16 Thread Scott Likens

On Jul 16, 2008, at 3:47 PM, Chet Farmer wrote:

We are comparing an Apple to a Pear, LAMP is not the same as LAMR  
or a Ruby on Rails install.  Please stop comparing it, you are  
doing nothing useful by doing that.


Are you really saying you can't compare a Ruby app with a LAMP app?  
That's ridiculous. How else can someone decide between Typo and MT  
and WP and etc?


No, you're just wrong. It makes PERFECT sense to compare the  
experience of setting up and using Application X with that of using  
Application Y if both X and Y are competitors in the same market  
(i.e., blogging software).


As I said above, you are doing nothing useful in this argument.  Stop  
it.  If you care that much passionately, then run Wordpress.  The  
argument is self defeating, because you are comparing apples to  
pears.  You can try this argument on a Django list and see how far you  
get.



What is mongrel? Let's see here if this quote satisfy's you.

Mongrel is a small library that provides a very fast HTTP 1.1  
server for Ruby web applications. It is not particular to any  
framework, and is intended to be just enough to get a web  
application running behind a more complete and robust web server.


What makes Mongrel so fast is the careful use of an Ragel extension  
to provide fast, accurate HTTP 1.1 protocol parsing. This makes the  
server scream without too many portability issues.


See mongrel.rubyforge.org for more information. 

A bit technical, but Mongrel is a Web Server.  Like Apache, or  
nginx or lighttpd.  Except that all it cares about and knows about  
is the application in which it is running.  Technically you can run  
it on port 80 (if you run it as root) and remove the whole extra  
web server from the equation.  Mongrel is for Ruby what mod_php is  
for Rails (bad analogy).  It does all the dirty work and forwards  
the end product to Apache and then to the end-user.  You can  
compare it to Tomcat or Jetty I guess, however that's not here nor  
there.


Why on earth would you need to run a second web server? That seems  
like a really bad idea, frankly, hence my annoyance that the most  
obvious question (which boils down to WTF?, essentially)  isn't  
addressed.


Then I suggest you to take that torch up with the Mongrel Mailing list  
and ask them.





Frédéric has pretty much gone into the other problems you addressed.

However, the best method of updating/upgrading typo depends on the  
backend.


Let's say you use SQLite3

1) backup your databases in db/ to a separate location
2) unarchive the new version of typo in a separate directory (for  
staging or testing purposes).
3) copy the backed up databases (do not move them, we want to keep  
a pristine copy still somewhere) to db/
4) verify you are using the proper environment (e.g. PRODUCTION /  
DEVELOPMENT ...) and then run rake db:migrate


What does rake do in this context?


Migrations.

To Quote from http://wiki.rubyonrails.org/rails/pages/UnderstandingMigrations

ActiveRecordMigration allows you to use Ruby to define changes to  
your database schema, making it possible to use a version control  
system to keep things synchronized with the actual code.

This has many uses, including:

* Teams of developers – if one person makes a schema change, the  
other developers just need to update, and run “rake db:migrate”.
* Production servers – run “rake db:migrate” when you roll out a  
new release to bring the database up to date as well.
* Multiple machines – if you develop on both a desktop and a  
laptop, or in more than one location, migrations can help you keep  
them all synchronized.


In essence, your database has a 'version' number in it, and if someone  
adds a new model, or changes a model a migration is also made.  So  
that you can run 'rake db:migrate' to ensure your database is up to  
date and able to do what the new version intends to do.




5) start typo on a different port then the original typo is running  
on.
6) Browse to the site by ip:port and verify if everything worked as  
planned, and if it did not discuss how it did not work properly,  
and if it did work how it can work easier.


Of course you'll have to reinstall your plugins and themes.




To put it mildly, that's a bit bizarre and very unfriendly to the  
user.


With the exception of plugins and themes, I find the upgrade process  
very relaxing and totally capable.  Very straight forward, and easy to  
do.  You can stage an upgrade painlessly and if there's a problem you  
have not affected your actual blog in any way what so ever.



I believe as a standard practice


Maybe for Typo. Not for anything else I use.


Remind me not to hire you as a Systems Administrator.  You should  
ALWAYS make a backup, upgrade in a an test environment and verify  
everything  happened properly before you roll out the new version.   
Now I realize that isn't as Cowboy as say Wordpress, where you just  
slap in the new version and it might upgrade 

Re: [typo] Deploying Ruby on Rails Applications (was: Re: Can't update feeds?)

2008-07-16 Thread Scott Likens


On Jul 16, 2008, at 5:09 PM, JZ wrote:


On Wed, Jul 16, 2008 at 4:22 AM, Scott Likens [EMAIL PROTECTED] wrote:


To whomever it may concern,
I notice the common thread here.  How to deploy typo?

There is many ways to deploy typo, the most common is
1) FastCGI.


We all know, it sucks.


It sucks, but it takes less memory to quote someone I know who uses  
Lighttpd + FastCGI.  His rather old RSS Reading application took 250  
Megabytes of memory, for which is not there in FastCGI Mode.



2) Mongrel/Webrick


Nginx with proxy load balancer to cluster of Thin/Ebb (+unix socket)
processes is a much faster.


If thin supported Streaming (Not Media, but the Mongrel Extension) it  
would be something I would have no issue using.  I've mentioned that  
to the author of Thin and we'll see how that goes.



3) Phusion Passenger (aka mod_rails?)


This is the best option. Fast and dead brain simple to deploy (just  
like PHP).



Now, there's no real difference with Mongrel/Webrick


Mongrel is much faster than Webrick. Thin is faster than Mongrel, and
Ebb is faster than Mongrel or Thin.


But those who have come from the PHP Boat (as we'll call
it, a/k/a wordpress, etc) they just untar files into a directory  
edit a few

files, loadup their web browser and bam.  It works.


Phusion mod_passenger  (http://www.modrails.com/) works in the very
same way. Just copy your files, load web browser and bam. It works.
Need to reload application? No problem. Create empty restart.txt file
in the tmp folder. Apache will reload the application. No need to
restart Apache. No SSH needed. Simple FTP access is all you need.
mod_passenger works also with others  Ruby frameworks which use
Rack,e.g. Merb. It even works also with Python... :)

You also forget mention Ruby Enterprise version which uses 33% less
memory... It works fine with mod_passenger and lowers the memory
footprint. http://www.rubyenterpriseedition.com/

mod_passenger is _the easiest option_  for deployment Rails
applications (including Typo).

But, there is also another, 4-th deploy option: JRuby. It is also
brain dead simple to deploy. Just create WAR file and copy it into
webapps Tomcat's folder. That's all!

sudo jruby -S gem install warbler, activerecord-jdbc-adapter
jruby -S rails my_app

For developing use: jruby script/server; jruby script/console etc.

For production, just create  ROOT.war file (with warble war command)
and copy it into webapps folder in Tomcat, Jetty or another Java
servlets container. This WAR file contains ALL gems (including JRuby
interpreter) so it works fine in all platforms.


I know a few people who have been deploying Merb apps in Tomcat that  
way.  I understand it's a very easy way to pass off a Merb app as a  
Java Webapp without someone knowing what it really is.  As far as  
Ruby Enterprise Version I was not aware of that, but like everything  
you don't always find all the options in 1 concise web page.



___
Typo-list mailing list
Typo-list@rubyforge.org
http://rubyforge.org/mailman/listinfo/typo-list


Re: [typo] Deploying Ruby on Rails Applications (was: Re: Can't update feeds?)

2008-07-16 Thread Kevin Williams
On Wed, Jul 16, 2008 at 6:22 PM, Scott Likens [EMAIL PROTECTED] wrote:

 If thin supported Streaming (Not Media, but the Mongrel Extension) it would
 be something I would have no issue using.  I've mentioned that to the author
 of Thin and we'll see how that goes.


Thin depends on the eventmachine library, which is not great for
uploads because it is more of a fire-and-forget event-driven
architecture and long-running requests mess it up. Mongrel is better
at uploads. There is a solution for this for Merb users:
http://brainspl.at/articles/2008/04/18/deferred-requests-with-merb-ebb-and-thin
I have no idea if something like this can be used in a Rails app, but
that would be up to Rails/Typo to make that happen.
___
Typo-list mailing list
Typo-list@rubyforge.org
http://rubyforge.org/mailman/listinfo/typo-list


Re: [typo] Deploying Ruby on Rails Applications (was: Re: Can't update feeds?)

2008-07-16 Thread Kevin Williams
On Wed, Jul 16, 2008 at 4:47 PM, Chet Farmer [EMAIL PROTECTED] wrote:

 Why on earth would you need to run a second web server? That seems like a
 really bad idea, frankly, hence my annoyance that the most obvious question
 (which boils down to WTF?, essentially)  isn't addressed.

Let's compare to a Wordpress blog run on Apache using mod_php. The PHP
code does not serves all requests. Apache serves up the static content
(css, javascript, graphics, etc.). Many popular front-end servers also
perform proxying and load balancing, and tons of other functions.
Mod_php just runs the PHP code. Most Ruby web apps are served in this
fashion rather than by an Apache module because it was easier to
implement (at the time mod_ruby was a memory-leaking nightmare) and it
is a more flexible design by virtue of not being tied to Apache and by
being proxyable behind any decent http proxy.

It's not a bad idea, it's a sound idea. Please settle down and ask
polite questions if you truly want to understand and use Typo.
___
Typo-list mailing list
Typo-list@rubyforge.org
http://rubyforge.org/mailman/listinfo/typo-list


Re: [typo] Deploying Ruby on Rails Applications (was: Re: Can't update feeds?)

2008-07-16 Thread Chet Farmer


On Jul 16, 2008, at 7:12 PM, Scott Likens wrote:
Are you really saying you can't compare a Ruby app with a LAMP app?  
That's ridiculous. How else can someone decide between Typo and MT  
and WP and etc?


No, you're just wrong. It makes PERFECT sense to compare the  
experience of setting up and using Application X with that of using  
Application Y if both X and Y are competitors in the same market  
(i.e., blogging software).


As I said above, you are doing nothing useful in this argument.   
Stop it.  If you care that much passionately, then run Wordpress.   
The argument is self defeating, because you are comparing apples to  
pears.  You can try this argument on a Django list and see how far  
you get.


The problem here, Scott, is that you're the one who's arguing. I  
stated an uncontroversial position -- RoR apps are harder to deploy  
than traditional LAMP apps -- and you've gone all apoplectic with  
fanboy protestations that, frankly, make no sense.


Look: I don't care. It's absolutely not important to me today, and I'm  
100% done with you. I have problems with Typo that Fred says he's  
working on, and I appreciate that. What I do NOT appreciate is your  
incessant browbeating and bombastic Ruby boosterism.


Why on earth would you need to run a second web server? That seems  
like a really bad idea, frankly, hence my annoyance that the most  
obvious question (which boils down to WTF?, essentially)  isn't  
addressed.


Then I suggest you to take that torch up with the Mongrel Mailing  
list and ask them.


If it's something that's considered a common part of a Typo install,  
then the Typo docs need to address it because it's out of the ordinary  
for weblogging software.



To Quote from http://wiki.rubyonrails.org/rails/pages/UnderstandingMigrations


I'll read this later. I am refreshed, however, that you've provided an  
apparently useful link.


In essence, your database has a 'version' number in it, and if  
someone adds a new model, or changes a model a migration is also  
made.  So that you can run 'rake db:migrate' to ensure your database  
is up to date and able to do what the new version intends to do.


Why is this better than just dropping the SQLite file into the tree  
after your re-install? (Hypothetically; I haven't tried it.)



Of course you'll have to reinstall your plugins and themes.




To put it mildly, that's a bit bizarre and very unfriendly to the  
user.


With the exception of plugins and themes, I find the upgrade process  
very relaxing and totally capable.


It's plugins and theme reinstallation I find bizarre.


I believe as a standard practice


Maybe for Typo. Not for anything else I use.


Remind me not to hire you as a Systems Administrator.


Based on my exposure to you here, it seems astoundingly unlikely  
you'll ever be in a position to hire anyone with my resume.


My reference here is to the need to reinstall plugins and themes, not  
standard pre-patch/pre-upgrade backups. In my career so far, my  
experience is much more defined by my own refusal to hire doctrinaire  
platform zealots.


Not to mention that is part of the Sarbanes-Oxley Compliance Matrix (http://www.crcdataprotection.com/solutions/sox_compliance.asp 
)


SarBox is so often a part of blog culture.


Because clearly I don't get it, and won't get it.



This, at least, is abundantly clear.

plonk

Chet Farmer

When you've got an RV, a jet pack, and a monkey you really don't need  
much actual content  - KS





___
Typo-list mailing list
Typo-list@rubyforge.org
http://rubyforge.org/mailman/listinfo/typo-list


[typo] Deploying Ruby on Rails Applications (was: Re: Can't update feeds?)

2008-07-15 Thread Scott Likens

To whomever it may concern,

I notice the common thread here.  How to deploy typo?

There is many ways to deploy typo, the most common is

1) FastCGI.  (It's also the most murky confusing documentation imo, I  
don't blame this on typo, I blame this on FastCGI Documentation and  
the people who wrote it).

2) Mongrel/Webrick
3) Phusion Passenger (aka mod_rails?)

Now, there's no real difference with Mongrel/Webrick if you run nginx  
or Apache or lighttpd.  It works, it's well documented and takes the  
most amount of memory (actually all of them really take the same  
amount of memory, you just don't see the ruby process hanging around  
using up 140megs of memory).  Phusion Passenger... Excellent option,  
if you have a cheap Dreamhost.com account that is going to be your  
easiest option, documentation is decent and it's much easier to deploy.


So there you have it, 3 basic methods to deploy your blog.  If your  
coding Ruby on Rails chances are this is nothing new to you, and you  
have no problem with it.  But those who have come from the PHP  
Boat (as we'll call it, a/k/a wordpress, etc) they just untar files  
into a directory edit a few files, loadup their web browser and bam.   
It works.  This is because the company behind PHP has spent a great  
deal of time and money at making PHP the dominant language.  It  
doesn't make it better, or worse or anything.  (It scales horribly  
also for those of you who are talking about scaling).  Let's say you  
grab a Perl based blog, what's your common problem?  Well mod_perl,  
perl with ithreads enabled.  Yeah you can use it as a cgi script and  
have it exec perl on each page/function.  But again, we'll go with it  
does not scale well.  We have Python and django, I know have not  
touched any of the django software really so I won't go there.


So let's bust out some simple myths,

Rails is hard to deploy, FALSE.  In fact Ruby on Rails Applications  
are quite easy to deploy provided your hosting company gives you an  
environment where it can deploy sanely.  This is something that DHH  
has commented on a few times; there is no way to make the pain of  
deploying a Ruby on Rails app on a bad/cheap hosting server go  
away.  Is that the fault of Ruby on Rails? or the company you chose to  
host with?  I'll let you decide on that one.


Rails does not scale, FALSE.  Ruby on Rails does Scale well if the  
developers write the application with scaling in mind.  Put the Rails  
app behind a Local Traffic Manager, and inject parts of the page to be  
pulled from services like Akami and other various things.  Look at  
Twitter and other Ruby on Rails based web apps.  Anyone who tells you  
that Ruby on Rails is not enterprise ready, lied to you.  Ask for your  
money back and tell them to get the heck out of your office.


Any questions? good great.

There is alternatives to Ruby on Rails, such as Merb (http://www.merbivore.com/ 
).  You can read the website about it, it's interesting, it's thread- 
safe and it's quite exciting.  Which brings me to Featherblog (http://featherblog.org 
).  It's currently a work in progress and is in no way shape or  
fashion complete.  However it's extremely fast, and will be more  
lightweight.  One of the developers of it (eldiablo)'s web site is  
running feather at http://crazycool.co.uk


My single point of this post is that there is great documentation (for  
the most part) on how to deploy Typo, or any other Rails app.  I will  
freely admit that the last decent version of typo in my personal  
opinion was typo 4.1.1.  That whole Rails 2.0 version really jaded me,  
and now Rails 2.1 is out.  Makes me more jaded, and is making me walk  
away from Rails as a viable option.  They are throwing out more and  
more versions, and quite frankly I have not kept up, I need to buy the  
new version of Pragmatic Programmers for Rails 2... which is already  
out of date as 2.1 is released :(


I think the best thing I can say out of this, is if your having a  
problem deploying Typo (or anything else) please file a bug, write an  
email, give as much detail as you can.  The more detail the better, so  
the developers of typo can find and squash the bugs.  Remember, if you  
don't raise your voice, you don't say this is broken; you have failed  
the community.  Just as much as you have failed the community if you  
fix what is broken, without reporting it and giving a patch so it can  
be addressed.  Not everyone is a developer, not everyone can program  
ruby on rails.  But Frédéric cannot fix a bug he is not aware of, nor  
can Piers.


Thank you for your time.

Sincerely,

Scott M. Likens___
Typo-list mailing list
Typo-list@rubyforge.org
http://rubyforge.org/mailman/listinfo/typo-list