Search code examples
coldfusionfusebox

development vs production fusebox.xml


I'm working on a Fusebox application using Coldfusion, and there is a fusebox.xml file which I'd like to be slightly different on the production server than it is on the development server. Since it appears that this file is just a xml file (ie: I don't think it can be a cfm file), it seems I cannot use some if..else.. logic within fusebox.xml.

So I'm wondering if my assumption above is wrong, or if there is a way to use two files, one for development and one for production?


Solution

  • Here is what I did:

    <!--For Development Mode =  "development-full-load" , For Production Mode = "production" -->
    <if condition="application.applicationname EQ 'xyz-dev'">
        <true>
            <parameter name="mode" value="development-full-load"/>
        </true>
        <false>
            <parameter name="mode" value="production"/>
        </false>
    </if>
    

    And obviously the application name is different for the production environment than it is for the development environment.