Accounts and subdomains

With reference to a previous
post:Sortable list (scriptalicious) and updating database - Rails - Ruby-Forum

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 :wink:

James W. 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] hosts (file) - Wikipedia

Dee Z. wrote:

James W. 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] hosts (file) - Wikipedia

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

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. :slight_smile:

On 2/19/06, James W. [email protected] wrote:

Can this be done automatically without manually editing a http config

[email protected]
http://lists.rubyonrails.org/mailman/listinfo/rails


=> the blog from beyond <=
=> www.eyeheartzombies.com <=