1 Reply Latest reply on Apr 7, 2008 3:33 AM by Oliver Goldman

    Loading external configuration when compiling AIR

    jarinudom Level 1
      I'm developing an AIR app using Flex Builder 3, but I'm using a deployment script (Capistrano) to deploy both the AIR file and the backend (Ruby on Rails) to various servers.

      The problem is that the AIR file needs to be able to point to different addresses based on which environment it was compiled for: development ( http://localhost:3000 ), staging ( http://my-staging-server ), and production ( http://my-production-cluster ).

      It seems that since there are 3 environments, the best option would be to have a constant set to http://localhost:3000 when developing, and have the deployment script change that constant by compiling the AIR file at deployment time using the command-line SDK. I think it should be somehow possible to do by using different config files as command-line options, but I am completely at a loss on how to do this. Any help would be greatly appreciated!