As mentioned in the 1st answer,
environment_indicator is the one you are looking for.
Well, we also use the same kind of development model and for ease of use if features module is used then you can have the settings written in a file. This makes the colour changing automated.
Follow the code below, this can be imported via Features module.
/**
* Implements hook_default_environment_indicator_environment().
*/
function mymodule_default_environment_indicator_environment() {
$export = array();
$environment = new stdClass();
$environment->disabled = FALSE; /* Edit this to true to make a default environment disabled initially */
$environment->api_version = 1;
$environment->machine = 'live';
$environment->name = 'Live';
$environment->regexurl = 'example.com';
$environment->settings = array(
'color' => '#bb0000',
'text_color' => '#ffffff',
'weight' => '',
'position' => 'top',
'fixed' => 0,
);
$export['live'] = $environment;
$environment = new stdClass();
$environment->disabled = FALSE; /* Edit this to true to make a default environment disabled initially */
$environment->api_version = 1;
$environment->machine = 'staging';
$environment->name = 'Staging';
$environment->regexurl = 'stage.example.com';
$environment->settings = array(
'color' => '#000099',
'text_color' => '#ffffff',
'weight' => '',
'position' => 'top',
'fixed' => 0,
);
$export['staging'] = $environment;
$environment = new stdClass();
$environment->disabled = FALSE; /* Edit this to true to make a default environment disabled initially */
$environment->api_version = 1;
$environment->machine = 'dev';
$environment->name = 'Dev';
$environment->regexurl = 'dev.example.com';
$environment->settings = array(
'color' => '#000066',
'text_color' => '#ffffff',
'weight' => '',
'position' => 'top',
'fixed' => 0,
);
$export['dev'] = $environment;
return $export;
}