diff options
| author | termie <github@anarkystic.com> | 2012-01-09 17:55:33 -0800 |
|---|---|---|
| committer | termie <github@anarkystic.com> | 2012-01-09 17:55:33 -0800 |
| commit | 732909a7be4e856f2a5c2a56778a852d42eec6c0 (patch) | |
| tree | 85f14a0319da5461fe6b06bee9365ae5202be8e9 /keystone | |
| parent | 3c88b7f546e727d8ae86901dd62b8230d1d85314 (diff) | |
add a db_sync command to bin/ks, remove others
Diffstat (limited to 'keystone')
| -rw-r--r-- | keystone/backends/sql/core.py | 6 | ||||
| -rw-r--r-- | keystone/config.py | 4 |
2 files changed, 8 insertions, 2 deletions
diff --git a/keystone/backends/sql/core.py b/keystone/backends/sql/core.py index a9a95bbe..5bebf3af 100644 --- a/keystone/backends/sql/core.py +++ b/keystone/backends/sql/core.py @@ -12,6 +12,7 @@ import sqlalchemy.engine.url from keystone import config from keystone import models +from keystone.backends.sql import migration CONF = config.CONF @@ -198,6 +199,11 @@ class SqlBase(object): class SqlIdentity(SqlBase): + # Internal interface to manage the database + def db_sync(self): + migration.db_sync() + + # Identity interface def authenticate(self, user_id=None, tenant_id=None, password=None): """Authenticate based on a user, tenant and password. diff --git a/keystone/config.py b/keystone/config.py index c2c7a924..796bb9b4 100644 --- a/keystone/config.py +++ b/keystone/config.py @@ -6,8 +6,8 @@ from keystone import cfg class Config(cfg.ConfigOpts): def __call__(self, config_files=None, *args, **kw): if config_files is not None: - self.config_file = config_files - super(Config, self).__call__(*args, **kw) + self._opts['config_file']['opt'].default = config_files + return super(Config, self).__call__(*args, **kw) def __getitem__(self, key, default=None): return getattr(self, key, default) |
