Dynamic database configuration?


#1

Hi,

I’m trying to run typo in multi user mode outside the box ( without
making too many modifications in core typo code ). I want to determine
database settings dynamically using subdomains. Could someone guide me
to the right direction ?

Thanks,
Pratik


#2

Anyone :-s ?


#3

On 5/23/06, Pratik removed_email_address@domain.invalid wrote:

Hi,

I’m trying to run typo in multi user mode outside the box ( without
making too many modifications in core typo code ). I want to determine
database settings dynamically using subdomains. Could someone guide me
to the right direction ?

I’m pretty sure that database.yml gets run through ERB before being read
by rails. So maybe use request.env[‘SERVER_NAME’] and do some stuff in
there to set it to what you want…?