def postOptions(self):
        if self['distribution'] is None:
            raise UsageError("Distribution required.")

        if self['config-file'] is not None:
            config_file = FilePath(self['config-file'])
            self['config'] = yaml.safe_load(config_file.getContent())
        else:
            self['config'] = {}

        if self.get('cert-directory') is None:
            self['cert-directory'] = FilePath(mkdtemp())

        if self.get('provider') is None:
            raise UsageError("Provider required.")
        provider = self['provider'].lower()
        provider_config = self['config'].get(provider, {})

        try:
            get_runner = getattr(self, "_runner_" + provider.upper())
        except __HOLE__:
            raise UsageError(
                "Provider {!r} not supported. Available providers: {}".format(
                    provider, ', '.join(
                        name.lower() for name in self._get_provider_names()
                    )
                )
            )
        else:
            self.runner = get_runner(
                package_source=self.package_source(),
                dataset_backend=self.dataset_backend(),
                provider_config=provider_config,
            )
dataset/ETHPy150Open ClusterHQ/flocker/admin/acceptance.py/CommonOptions.postOptions