Forum: Ruby on Rails accounts and subdomains

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.
B0be4bfef5a22697a0f44f4fe295aaef?d=identicon&s=25 James Whittaker (aftershock)
on 2006-02-19 19:57
With reference to a previous
post:http://www.ruby-forum.com/topic/55201#new

I would like my app to function as follows:

A new user signs up for my application, his username is "andy". When
andy now logs in to the application the url is redirected to :
http://andy.myapplication.com

Questions:

Is this possible to develop on a windows box with webrick?
Do I need anything special like lighttpd to achieve this?
Can this be done automatically without manually editing a http config
file?

Alternative:

As an alternative I could have the url look like:
http://www.myapplication.com/andy
so that an operation could be then located at:
http://www.myapplication.com/andy/articles/list

Questions:
Is this better to use for developing on a standalone system?
Could I then use routes to achieve this?
Is this recommended over the first option?

I need to get this resolved before I commence building as it will affect
all the controllers etc.

Thanks ;-)
15619be638a3ae3d6f86a4995c6484c1?d=identicon&s=25 Dee Zsombor (Guest)
on 2006-02-19 22:20
(Received via mailing list)
James Whittaker wrote:
> A new user signs up for my application, his username is "andy". When
> andy now logs in to the application the url is redirected to :
> http://andy.myapplication.com
>
> Questions:
>
> Is this possible to develop on a windows box with webrick?
> Do I need anything special like lighttpd to achieve this?
> Can this be done automatically without manually editing a http config
> file?

You'll need is to edit your host file[1], inserting values for
localhost.com and andy.localhost.com. Sure the real localhost.com will
be
 unreachable after this, but in return you'll have nice subdomained
system
   localhosted as it suits you better.

[1] http://en.wikipedia.org/wiki/Hosts_file
B0be4bfef5a22697a0f44f4fe295aaef?d=identicon&s=25 James Whittaker (aftershock)
on 2006-02-19 22:46
Dee Zsombor wrote:
> James Whittaker wrote:
>> A new user signs up for my application, his username is "andy". When
>> andy now logs in to the application the url is redirected to :
>> http://andy.myapplication.com
>>
>> Questions:
>>
>> Is this possible to develop on a windows box with webrick?
>> Do I need anything special like lighttpd to achieve this?
>> Can this be done automatically without manually editing a http config
>> file?
>
> You'll need is to edit your host file[1], inserting values for
> localhost.com and andy.localhost.com. Sure the real localhost.com will
> be
>  unreachable after this, but in return you'll have nice subdomained
> system
>    localhosted as it suits you better.
>
> [1] http://en.wikipedia.org/wiki/Hosts_file

Yes your right but I would like to automate the whole process just like
backpack etc does. When a user signs up for an account a new subdomain
is created so that when he logs in he sees something like:
http://www.myapplication.com/andy
895715ccced713d61a5cce1d492a958d?d=identicon&s=25 Kenneth Love (Guest)
on 2006-02-19 23:05
(Received via mailing list)
you'd only have to do the host file on your local system; online with
a real DNS server behind it, it should be automatic.

you could always install a DNS server at home. :)

On 2/19/06, James Whittaker <jmwhittaker@gmail.com> wrote:
> >> Can this be done automatically without manually editing a http config
>
> Rails@lists.rubyonrails.org
> http://lists.rubyonrails.org/mailman/listinfo/rails
>


--
=> the blog from beyond <=
=> www.eyeheartzombies.com <=
This topic is locked and can not be replied to.