'Update self from a dict.'

def _apply(self, config):

    which_env = config.get('environment')
    if which_env:
        env = self.environments[which_env]
        for k in env:
            if (k not in config):
                config[k] = env[k]
    dict.update(self, config)
    self.namespaces(config)
