Forum: Ruby on Rails multiple rails apps on one lighttpd

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
Matthew (Guest)
on 2005-11-23 01:46
Good evening (or afternoon or whatever it is where you are),

Before I start setting it all up, I have a question about lighttpd and
multiple rails apps. From what I have read, it is at the minute only
possible to do multiple rails apps using subdomains:
typo.mysite.com
hieraki.mysite.com
rforum.mysite.com
etc, etc

and not currently possible to do this:
mysite.com/typo
mysite.com/rforums
mysite.com/hieraki

Is this correct??

I read on a thread in textdrive that this will be possbile in lighty
1.4.8 which is apparently out soon.

Also, does anybody know if it's possible to do several rails apps as
above and also have the homne page and some other homegrown pages run by
rails..

/(index.rhtml from rails)
/typo
/rfoums
/hierarki
/HomeGrownRailsPages

Thank you.

Matthew Bennett
W. andrew L. (Guest)
on 2005-11-23 06:24
Matthew wrote:
> Good evening (or afternoon or whatever it is where you are),
>
> Before I start setting it all up, I have a question about lighttpd and
> multiple rails apps. From what I have read, it is at the minute only
> possible to do multiple rails apps using subdomains:
> typo.mysite.com
> hieraki.mysite.com
> rforum.mysite.com
> etc, etc
>
> and not currently possible to do this:
> mysite.com/typo
> mysite.com/rforums
> mysite.com/hieraki
>
> Is this correct??
>
> I read on a thread in textdrive that this will be possbile in lighty
> 1.4.8 which is apparently out soon.
>
> Also, does anybody know if it's possible to do several rails apps as
> above and also have the homne page and some other homegrown pages run by
> rails..
>
> /(index.rhtml from rails)
> /typo
> /rfoums
> /hierarki
> /HomeGrownRailsPages
>
> Thank you.
>
> Matthew Bennett

Use symbolic links! You would have the applications in their own
directories, then simply use a symbolic link to make mydomain.com/rforum
point to /var/www/rforum or wherever else you want. Rails will
dynamically adjust the urls (you did use link_to and all the helpers for
a reason!)
Matthew (Guest)
on 2005-11-23 09:34
> Use symbolic links! You would have the applications in their own
> directories, then simply use a symbolic link to make mydomain.com/rforum
> point to /var/www/rforum or wherever else you want. Rails will
> dynamically adjust the urls (you did use link_to and all the helpers for
> a reason!)

Thanks waloeii, that sounds interesting. Is it as simple as doing:

ln -s /home/username/www/blog/ /home/username/blog/ etc, etc??

Also, how is this represented externally in browsers and to search
spiders..?? What URI do I use? Do the symlinks mean I can do
mysite.com/blog (and this URI continues to appear in the browser) or
does it redirect to blog.mysit.com??

I'm coming at this mainly from an SEO perspective: search spiders treat
subdomains as completely different sites (from a ranking and results
point of view).

So if you have 1000 incoming links, for example, that all point to
things like mysite.com/blog, mysite.com/nextthing etcc then all of those
incoming links count towartds one site and all the content is judged
together. If however you have 1000 links to three subdomains (blog,
forums, articles) then that's going to split your search karma over 3
sites, even though you know and your visitors know that they're the same
one.

Thanks for your suggestion.

Matthew
Matthew <> <matthew@mjbennett (Guest)
on 2005-11-24 00:22
Now solved, lighty 1.4.8 is here. Well done the lighttpd people!!

http://blog.lighttpd.net/articles/2005/11/23/light...
andi (Guest)
on 2005-11-24 16:21
(Received via mailing list)
Hi Guys,

after doing first steps with rails i?ve a simple question about how
to best do data-type-conversion from/to forms:

I have a form that accepts data of an Event like: title, time etc.
This is mapped to a AR model object called Event. Additionally there
is a field that accepts a comma speparated list of email addresses -
the people that should be notified. Each email address should be
converted to a single active record model objects of type
'Invitee' (Event has_many :invitees).

Now I don't know where to put the validation and data preperation of
those email addresses!? In the java world i would have created a
ProperyEditor. In Rails i could add the comma delimited field as
additional attribute to the Event model class (where it does not
really belong, does it?). Or i could put it in the controller by
using a extra fieldname out of the event context but only have the
flash for error reporting in this case.

Where would you put it? Any best practices here? I?m a little bit
lost on this.

Thanks a lot
Andi_______________________________________________
Rails mailing list
removed_email_address@domain.invalid
http://lists.rubyonrails.org/mailman/listinfo/rails
This topic is locked and can not be replied to.