1.修改nova的api-paste.ini文件,找到composite:openstack_compute_api_v2条目:
将
keystone = faultwrap sizelimit authtoken keystonecontext ratelimit osapi_compute_app_v2修改为
Keystone = faultwrap sizelimit noauth ratelimit osapi_compute_app_v2
2.根据noauth这个filter的指向
[filter:noauth]
paste.filter_factory = nova.api.openstack.auth:NoAuthMiddleware.factory修改nova.api.openstack.auth:NoAuthMiddleware这个方法:
将base_call函数中
token = req.headers['X-Auth-Token']
user_id, _sep, project_id = token.partition(':')
project_id = project_id or user_id修改为
token = req.headers['X-Auth-Token']
user_id = req.headers.get('X-Auth-User', 'admin')
project_id = req.headers.get('X-Auth-Project-
406




被折叠的 条评论
为什么被折叠?



