From: Marcus Watts Date: Wed, 30 May 2018 20:37:31 +0000 (-0400) Subject: rgw: making implicit_tenants backwards compatible. X-Git-Tag: v15.1.0~1944^2~21 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=3ba7be8d1ac7ee43e69eebb58263cd080cca1d38;p=ceph.git rgw: making implicit_tenants backwards compatible. In jewel, "rgw keystone implicit tenants" only applied to swift. As of luminous), this option applies to s3 also. Sites that used this feature with jewel now have outstanding data that depends on the old behavior. The fix here is to expand "rgw keystone implicit tenants" so that it can be set to any of "none", "all", "s3" or "swift" (also 0=false=none, 1=true=all). When set to "s3" or "swift", the actual id lookup is also partitioned. Formerly "rgw keystone implicit tenants" was a legacy opt. This change converts it to the new style of option, including support for dynamically changing it. Fixes: http://tracker.ceph.com/issues/24348 Signed-off-by: Marcus Watts --- diff --git a/doc/radosgw/keystone.rst b/doc/radosgw/keystone.rst index ce889e079a9..628810ad3ca 100644 --- a/doc/radosgw/keystone.rst +++ b/doc/radosgw/keystone.rst @@ -46,6 +46,13 @@ For a v3 version of the OpenStack Identity API you should replace rgw keystone admin domain = {keystone admin domain name} rgw keystone admin project = {keystone admin project name} +For compatibility with previous versions of ceph, it is also +possible to set ``rgw keystone implicit tenants`` to either +``s3`` or ``swift``. This has the effect of splitting +the identity space such that the indicated protocol will +only use implicit tenants, and the other protocol will +never use implicit tenants. Some older versions of ceph +only supported implicit tenants with swift. Ocata (and later) ----------------- diff --git a/doc/radosgw/multitenancy.rst b/doc/radosgw/multitenancy.rst index b6d76c7575f..0cca50d966e 100644 --- a/doc/radosgw/multitenancy.rst +++ b/doc/radosgw/multitenancy.rst @@ -154,6 +154,13 @@ are two or more different tenants all creating a container named ``foo``, radosgw is able to transparently discern them by their tenant prefix. +It is also possible to limit the effects of implicit tenants +to only apply to swift or s3, by setting ``rgw keystone implicit tenants`` +to either ``s3`` or ``swift``. This will likely primarily +be of use to users who had previously used implicit tenants +with older versions of ceph, where implicit tenants +only applied to the swift protocol. + Notes and known issues ---------------------- diff --git a/src/common/legacy_config_opts.h b/src/common/legacy_config_opts.h index df13b12c80f..2215ec19c48 100644 --- a/src/common/legacy_config_opts.h +++ b/src/common/legacy_config_opts.h @@ -1332,7 +1332,6 @@ OPTION(rgw_keystone_accepted_roles, OPT_STR) // roles required to serve request OPTION(rgw_keystone_accepted_admin_roles, OPT_STR) // list of roles allowing an user to gain admin privileges OPTION(rgw_keystone_token_cache_size, OPT_INT) // max number of entries in keystone token cache OPTION(rgw_keystone_verify_ssl, OPT_BOOL) // should we try to verify keystone's ssl -OPTION(rgw_keystone_implicit_tenants, OPT_BOOL) // create new users in their own tenants of the same name OPTION(rgw_cross_domain_policy, OPT_STR) OPTION(rgw_healthcheck_disabling_path, OPT_STR) // path that existence causes the healthcheck to respond 503 OPTION(rgw_s3_auth_use_rados, OPT_BOOL) // should we try to use the internal credentials for s3? diff --git a/src/common/options.cc b/src/common/options.cc index c9160fc6c27..9ca05d60531 100644 --- a/src/common/options.cc +++ b/src/common/options.cc @@ -5898,12 +5898,13 @@ std::vector