Re: rgw subuser create and admin api
On Thu, Dec 17, 2015 at 9:04 AM, Derek Yarnellwrote: > I am having an issue with the 'radosgw-admin subuser create' command > doing something different than the '/{admin}/user?subuser=json' > admin API. I want to leverage subusers in S3 which looks to be possible > in my testing for bit more control without resorting to ACLs. > > radosgw-admin subuser create --uid=-staff --subuser=test1 > --access-key=a --secret=z --access=read > > This command will work and create a both a subuser -staff:test1 with > permission read and a s3 key with the the correct access and secret key set. > > The Admin API will not allow me to do this it would seem as the > following is accepted and a subuser is created however a swift_key is > created instead. > > DEBUG:requests.packages.urllib3.connectionpool:"PUT > /admin/user?subuser=json=-staff=test2=b=cc=read > HTTP/1.1" 200 130 > > The documentation for the admin API[0] does not seem to indicate that > access-key is accepted at all. Also if you pass key-type=s3 it will > return a 400 with InvalidArgument although the documentation says it > should accept the key type s3. > > Bug? Design? Somewhat a bug. The whole subusers that use s3 was unintentional, so when creating the subuser api, we didn't think of needing the access key. For some reason we do get the key type. Can you open a ceph tracker issue for that? You can try using the metadata api to modify the user once it has been created (need to get the user info, add the s3 key to the structure, put the user info). > > One other issue is that a command that uses the --purge-keys from > radosgw-admin seems to have no effect. The following command removes > the subuser and leaves the swift keys it has (but also any s3 keys too). > > radosgw-admin subuser rm --uid=-staff --subuser=test2 --purge-keys > It's a known issue, and it will be fixed soon (so it seems). Thanks, Yehuda > > [0] - http://docs.ceph.com/docs/master/radosgw/adminops/#create-subuser > > > -- > Derek T. Yarnell > University of Maryland > Institute for Advanced Computer Studies > -- > To unsubscribe from this list: send the line "unsubscribe ceph-devel" in > the body of a message to majord...@vger.kernel.org > More majordomo info at http://vger.kernel.org/majordomo-info.html -- To unsubscribe from this list: send the line "unsubscribe ceph-devel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: rgw subuser create and admin api
On Thu, Dec 17, 2015 at 12:06 PM, Derek Yarnellwrote: > On 12/17/15 2:36 PM, Yehuda Sadeh-Weinraub wrote: >> Try 'section=user=cephtests' > > Doesn't seem to work either. > > # radosgw-admin metadata get user:cephtest > { > "key": "user:cephtest", > "ver": { > "tag": "_dhpzgdOjqJI-OsR1MsYV5-p", > "ver": 1 > }, > "mtime": 1450378246, > "data": { > "user_id": "cephtest", > "display_name": "Ceph Test", > "email": "", > "suspended": 0, > "max_buckets": 1000, > "auid": 0, > "subusers": [], > "keys": [ > { > "user": "cephtest", > "access_key": "eee", > "secret_key": "" > }, > { > "user": "cephtest", > "access_key": "aaa", > "secret_key": "" > } > ], > "swift_keys": [], > "caps": [], > "op_mask": "read, write, delete", > "default_placement": "", > "placement_tags": [], > "bucket_quota": { > "enabled": false, > "max_size_kb": -1, > "max_objects": -1 > }, > "user_quota": { > "enabled": false, > "max_size_kb": -1, > "max_objects": -1 > }, > "temp_url_keys": [] > } > } > > > 2015-12-17 15:03:41.126024 7f88ef7e6700 20 RGWEnv::set(): HTTP_HOST: > localhost:7480 > 2015-12-17 15:03:41.126056 7f88ef7e6700 20 RGWEnv::set(): HTTP_DATE: > Thu, 17 Dec 2015 20:03:41 GMT > 2015-12-17 15:03:41.126059 7f88ef7e6700 20 RGWEnv::set(): HTTP_ACCEPT: */* > 2015-12-17 15:03:41.126064 7f88ef7e6700 20 RGWEnv::set(): > HTTP_ACCEPT_ENCODING: gzip, deflate > 2015-12-17 15:03:41.126066 7f88ef7e6700 20 RGWEnv::set(): > HTTP_AUTHORIZATION: AWS RTJ1TL13CH613JRU2PJD:F6wMKxSrrFhl2m3fyo/M0yXIGT8= > 2015-12-17 15:03:41.126070 7f88ef7e6700 20 RGWEnv::set(): > HTTP_USER_AGENT: python-requests/2.3.0 CPython/2.7.10 Darwin/14.5.0 > 2015-12-17 15:03:41.126071 7f88ef7e6700 20 RGWEnv::set(): > HTTP_X_FORWARDED_FOR: 192.168.86.254 > 2015-12-17 15:03:41.126073 7f88ef7e6700 20 RGWEnv::set(): > HTTP_X_FORWARDED_HOST: ceph.umiacs.umd.edu > 2015-12-17 15:03:41.126075 7f88ef7e6700 20 RGWEnv::set(): > HTTP_X_FORWARDED_SERVER: cephproxy00.umiacs.umd.edu > 2015-12-17 15:03:41.126077 7f88ef7e6700 20 RGWEnv::set(): > HTTP_CONNECTION: Keep-Alive > 2015-12-17 15:03:41.126079 7f88ef7e6700 20 RGWEnv::set(): > REQUEST_METHOD: GET > 2015-12-17 15:03:41.126080 7f88ef7e6700 20 RGWEnv::set(): REQUEST_URI: > /admin/metadata/get > 2015-12-17 15:03:41.126081 7f88ef7e6700 20 RGWEnv::set(): QUERY_STRING: > section=user=cephtest > 2015-12-17 15:03:41.126082 7f88ef7e6700 20 RGWEnv::set(): REMOTE_USER: > 2015-12-17 15:03:41.126083 7f88ef7e6700 20 RGWEnv::set(): SCRIPT_URI: > /admin/metadata/get > 2015-12-17 15:03:41.126089 7f88ef7e6700 20 RGWEnv::set(): SERVER_PORT: 7480 > 2015-12-17 15:03:41.126090 7f88ef7e6700 20 HTTP_ACCEPT=*/* > 2015-12-17 15:03:41.126093 7f88ef7e6700 20 HTTP_ACCEPT_ENCODING=gzip, > deflate > 2015-12-17 15:03:41.126094 7f88ef7e6700 20 HTTP_AUTHORIZATION=AWS > RTJ1TL13CH613JRU2PJD:F6wMKxSrrFhl2m3fyo/M0yXIGT8= > 2015-12-17 15:03:41.126094 7f88ef7e6700 20 HTTP_CONNECTION=Keep-Alive > 2015-12-17 15:03:41.126095 7f88ef7e6700 20 HTTP_DATE=Thu, 17 Dec 2015 > 20:03:41 GMT > 2015-12-17 15:03:41.126095 7f88ef7e6700 20 HTTP_HOST=localhost:7480 > 2015-12-17 15:03:41.126096 7f88ef7e6700 20 > HTTP_USER_AGENT=python-requests/2.3.0 CPython/2.7.10 Darwin/14.5.0 > 2015-12-17 15:03:41.126097 7f88ef7e6700 20 > HTTP_X_FORWARDED_FOR=192.168.86.254 > 2015-12-17 15:03:41.126097 7f88ef7e6700 20 > HTTP_X_FORWARDED_HOST=ceph.umiacs.umd.edu > 2015-12-17 15:03:41.126098 7f88ef7e6700 20 > HTTP_X_FORWARDED_SERVER=cephproxy00.umiacs.umd.edu > 2015-12-17 15:03:41.126099 7f88ef7e6700 20 > QUERY_STRING=section=user=cephtest > 2015-12-17 15:03:41.126099 7f88ef7e6700 20 REMOTE_USER= > 2015-12-17 15:03:41.126100 7f88ef7e6700 20 REQUEST_METHOD=GET > 2015-12-17 15:03:41.126101 7f88ef7e6700 20 REQUEST_URI=/admin/metadata/get > 2015-12-17 15:03:41.126101 7f88ef7e6700 20 SCRIPT_URI=/admin/metadata/get > 2015-12-17 15:03:41.126102 7f88ef7e6700 20 SERVER_PORT=7480 > 2015-12-17 15:03:41.126104 7f88ef7e6700 20 RGWEnv::set(): HTTP_HOST: > localhost:7480 > 2015-12-17 15:03:41.126105 7f88ef7e6700 20 RGWEnv::set(): HTTP_DATE: > Thu, 17 Dec 2015 20:03:41 GMT > 2015-12-17 15:03:41.126107 7f88ef7e6700 20 RGWEnv::set(): HTTP_ACCEPT: */* > 2015-12-17 15:03:41.126108 7f88ef7e6700 20 RGWEnv::set(): > HTTP_ACCEPT_ENCODING: gzip, deflate > 2015-12-17 15:03:41.126110 7f88ef7e6700 20 RGWEnv::set(): > HTTP_AUTHORIZATION: AWS RTJ1TL13CH613JRU2PJD:F6wMKxSrrFhl2m3fyo/M0yXIGT8= > 2015-12-17 15:03:41.126113 7f88ef7e6700 20 RGWEnv::set(): > HTTP_USER_AGENT: python-requests/2.3.0 CPython/2.7.10
Re: rgw subuser create and admin api
On 12/17/15 2:36 PM, Yehuda Sadeh-Weinraub wrote: > Try 'section=user=cephtests' Doesn't seem to work either. # radosgw-admin metadata get user:cephtest { "key": "user:cephtest", "ver": { "tag": "_dhpzgdOjqJI-OsR1MsYV5-p", "ver": 1 }, "mtime": 1450378246, "data": { "user_id": "cephtest", "display_name": "Ceph Test", "email": "", "suspended": 0, "max_buckets": 1000, "auid": 0, "subusers": [], "keys": [ { "user": "cephtest", "access_key": "eee", "secret_key": "" }, { "user": "cephtest", "access_key": "aaa", "secret_key": "" } ], "swift_keys": [], "caps": [], "op_mask": "read, write, delete", "default_placement": "", "placement_tags": [], "bucket_quota": { "enabled": false, "max_size_kb": -1, "max_objects": -1 }, "user_quota": { "enabled": false, "max_size_kb": -1, "max_objects": -1 }, "temp_url_keys": [] } } 2015-12-17 15:03:41.126024 7f88ef7e6700 20 RGWEnv::set(): HTTP_HOST: localhost:7480 2015-12-17 15:03:41.126056 7f88ef7e6700 20 RGWEnv::set(): HTTP_DATE: Thu, 17 Dec 2015 20:03:41 GMT 2015-12-17 15:03:41.126059 7f88ef7e6700 20 RGWEnv::set(): HTTP_ACCEPT: */* 2015-12-17 15:03:41.126064 7f88ef7e6700 20 RGWEnv::set(): HTTP_ACCEPT_ENCODING: gzip, deflate 2015-12-17 15:03:41.126066 7f88ef7e6700 20 RGWEnv::set(): HTTP_AUTHORIZATION: AWS RTJ1TL13CH613JRU2PJD:F6wMKxSrrFhl2m3fyo/M0yXIGT8= 2015-12-17 15:03:41.126070 7f88ef7e6700 20 RGWEnv::set(): HTTP_USER_AGENT: python-requests/2.3.0 CPython/2.7.10 Darwin/14.5.0 2015-12-17 15:03:41.126071 7f88ef7e6700 20 RGWEnv::set(): HTTP_X_FORWARDED_FOR: 192.168.86.254 2015-12-17 15:03:41.126073 7f88ef7e6700 20 RGWEnv::set(): HTTP_X_FORWARDED_HOST: ceph.umiacs.umd.edu 2015-12-17 15:03:41.126075 7f88ef7e6700 20 RGWEnv::set(): HTTP_X_FORWARDED_SERVER: cephproxy00.umiacs.umd.edu 2015-12-17 15:03:41.126077 7f88ef7e6700 20 RGWEnv::set(): HTTP_CONNECTION: Keep-Alive 2015-12-17 15:03:41.126079 7f88ef7e6700 20 RGWEnv::set(): REQUEST_METHOD: GET 2015-12-17 15:03:41.126080 7f88ef7e6700 20 RGWEnv::set(): REQUEST_URI: /admin/metadata/get 2015-12-17 15:03:41.126081 7f88ef7e6700 20 RGWEnv::set(): QUERY_STRING: section=user=cephtest 2015-12-17 15:03:41.126082 7f88ef7e6700 20 RGWEnv::set(): REMOTE_USER: 2015-12-17 15:03:41.126083 7f88ef7e6700 20 RGWEnv::set(): SCRIPT_URI: /admin/metadata/get 2015-12-17 15:03:41.126089 7f88ef7e6700 20 RGWEnv::set(): SERVER_PORT: 7480 2015-12-17 15:03:41.126090 7f88ef7e6700 20 HTTP_ACCEPT=*/* 2015-12-17 15:03:41.126093 7f88ef7e6700 20 HTTP_ACCEPT_ENCODING=gzip, deflate 2015-12-17 15:03:41.126094 7f88ef7e6700 20 HTTP_AUTHORIZATION=AWS RTJ1TL13CH613JRU2PJD:F6wMKxSrrFhl2m3fyo/M0yXIGT8= 2015-12-17 15:03:41.126094 7f88ef7e6700 20 HTTP_CONNECTION=Keep-Alive 2015-12-17 15:03:41.126095 7f88ef7e6700 20 HTTP_DATE=Thu, 17 Dec 2015 20:03:41 GMT 2015-12-17 15:03:41.126095 7f88ef7e6700 20 HTTP_HOST=localhost:7480 2015-12-17 15:03:41.126096 7f88ef7e6700 20 HTTP_USER_AGENT=python-requests/2.3.0 CPython/2.7.10 Darwin/14.5.0 2015-12-17 15:03:41.126097 7f88ef7e6700 20 HTTP_X_FORWARDED_FOR=192.168.86.254 2015-12-17 15:03:41.126097 7f88ef7e6700 20 HTTP_X_FORWARDED_HOST=ceph.umiacs.umd.edu 2015-12-17 15:03:41.126098 7f88ef7e6700 20 HTTP_X_FORWARDED_SERVER=cephproxy00.umiacs.umd.edu 2015-12-17 15:03:41.126099 7f88ef7e6700 20 QUERY_STRING=section=user=cephtest 2015-12-17 15:03:41.126099 7f88ef7e6700 20 REMOTE_USER= 2015-12-17 15:03:41.126100 7f88ef7e6700 20 REQUEST_METHOD=GET 2015-12-17 15:03:41.126101 7f88ef7e6700 20 REQUEST_URI=/admin/metadata/get 2015-12-17 15:03:41.126101 7f88ef7e6700 20 SCRIPT_URI=/admin/metadata/get 2015-12-17 15:03:41.126102 7f88ef7e6700 20 SERVER_PORT=7480 2015-12-17 15:03:41.126104 7f88ef7e6700 20 RGWEnv::set(): HTTP_HOST: localhost:7480 2015-12-17 15:03:41.126105 7f88ef7e6700 20 RGWEnv::set(): HTTP_DATE: Thu, 17 Dec 2015 20:03:41 GMT 2015-12-17 15:03:41.126107 7f88ef7e6700 20 RGWEnv::set(): HTTP_ACCEPT: */* 2015-12-17 15:03:41.126108 7f88ef7e6700 20 RGWEnv::set(): HTTP_ACCEPT_ENCODING: gzip, deflate 2015-12-17 15:03:41.126110 7f88ef7e6700 20 RGWEnv::set(): HTTP_AUTHORIZATION: AWS RTJ1TL13CH613JRU2PJD:F6wMKxSrrFhl2m3fyo/M0yXIGT8= 2015-12-17 15:03:41.126113 7f88ef7e6700 20 RGWEnv::set(): HTTP_USER_AGENT: python-requests/2.3.0 CPython/2.7.10 Darwin/14.5.0 2015-12-17 15:03:41.126115 7f88ef7e6700 20 RGWEnv::set(): HTTP_X_FORWARDED_FOR: 192.168.86.254 2015-12-17 15:03:41.126117 7f88ef7e6700 20 RGWEnv::set(): HTTP_X_FORWARDED_HOST: ceph.umiacs.umd.edu 2015-12-17 15:03:41.126119 7f88ef7e6700 20 RGWEnv::set(): HTTP_X_FORWARDED_SERVER: cephproxy00.umiacs.umd.edu
Re: rgw subuser create and admin api
On 12/17/15 1:09 PM, Yehuda Sadeh-Weinraub wrote: >> Bug? Design? > > Somewhat a bug. The whole subusers that use s3 was unintentional, so > when creating the subuser api, we didn't think of needing the access > key. For some reason we do get the key type. Can you open a ceph > tracker issue for that? > > You can try using the metadata api to modify the user once it has been > created (need to get the user info, add the s3 key to the structure, > put the user info). > This will actually create a subuser and the S3 keys correctly (but not let you specify the access_key and secret_key). DEBUG:requests.packages.urllib3.connectionpool:"PUT /admin/user?subuser=json=-staff=test3=s3=read=True HTTP/1.1" 200 87 I know about a 'GET /admin/metadata/user?format=json' to get the list of users from the adminops. I see I can do things like 'radosgw-admin metadata get user:cephtest' but I can't seem to get something like this to work. DEBUG:requests.packages.urllib3.connectionpool:"GET /admin/metadata/get?format=json=user%3Acephtest HTTP/1.1" 404 20 ERROR:rgwadmin.rgw:{u'Code': u'NoSuchKey'} -- Derek T. Yarnell University of Maryland Institute for Advanced Computer Studies -- To unsubscribe from this list: send the line "unsubscribe ceph-devel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: rgw subuser create and admin api
On Thu, Dec 17, 2015 at 11:05 AM, Derek Yarnellwrote: > On 12/17/15 1:09 PM, Yehuda Sadeh-Weinraub wrote: >>> Bug? Design? >> >> Somewhat a bug. The whole subusers that use s3 was unintentional, so >> when creating the subuser api, we didn't think of needing the access >> key. For some reason we do get the key type. Can you open a ceph >> tracker issue for that? >> >> You can try using the metadata api to modify the user once it has been >> created (need to get the user info, add the s3 key to the structure, >> put the user info). >> > > This will actually create a subuser and the S3 keys correctly (but not > let you specify the access_key and secret_key). > > DEBUG:requests.packages.urllib3.connectionpool:"PUT > /admin/user?subuser=json=-staff=test3=s3=read=True > HTTP/1.1" 200 87 > > I know about a 'GET /admin/metadata/user?format=json' to get the list of > users from the adminops. I see I can do things like 'radosgw-admin > metadata get user:cephtest' but I can't seem to get something like this > to work. > > DEBUG:requests.packages.urllib3.connectionpool:"GET > /admin/metadata/get?format=json=user%3Acephtest HTTP/1.1" 404 20 > ERROR:rgwadmin.rgw:{u'Code': u'NoSuchKey'} > Try 'section=user=cephtests' > > -- > Derek T. Yarnell > University of Maryland > Institute for Advanced Computer Studies -- To unsubscribe from this list: send the line "unsubscribe ceph-devel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
Re: rgw subuser create and admin api
On 12/17/15 3:15 PM, Yehuda Sadeh-Weinraub wrote: > > Right. Reading the code again: > > Try: > GET /admin/metadata/user=cephtest Thanks this is very helpful and works and I was able to also get the PUT working. Only question is that is it expected to return a 204 no content? 2015-12-17 17:42:39.422612 7f88f47f0700 20 RGWEnv::set(): HTTP_HOST: localhost:7480 2015-12-17 17:42:39.422619 7f88f47f0700 20 RGWEnv::set(): HTTP_ACCEPT_ENCODING: gzip, deflate 2015-12-17 17:42:39.422621 7f88f47f0700 20 RGWEnv::set(): HTTP_ACCEPT: */* 2015-12-17 17:42:39.422623 7f88f47f0700 20 RGWEnv::set(): HTTP_USER_AGENT: python-requests/2.3.0 CPython/2.7.10 Darwin/14.5.0 2015-12-17 17:42:39.422625 7f88f47f0700 20 RGWEnv::set(): HTTP_DATE: Thu, 17 Dec 2015 22:42:39 GMT 2015-12-17 17:42:39.422627 7f88f47f0700 20 RGWEnv::set(): CONTENT_TYPE: application/json 2015-12-17 17:42:39.422629 7f88f47f0700 20 RGWEnv::set(): HTTP_AUTHORIZATION: AWS RTJ1TL13CH613JRU2PJD:K3xaPHDy6t3r0COfjwl9rAUsUfY= 2015-12-17 17:42:39.422630 7f88f47f0700 20 RGWEnv::set(): HTTP_X_FORWARDED_FOR: 192.168.86.254 2015-12-17 17:42:39.422632 7f88f47f0700 20 RGWEnv::set(): HTTP_X_FORWARDED_HOST: ceph.umiacs.umd.edu 2015-12-17 17:42:39.422634 7f88f47f0700 20 RGWEnv::set(): HTTP_X_FORWARDED_SERVER: cephproxy00.umiacs.umd.edu 2015-12-17 17:42:39.422636 7f88f47f0700 20 RGWEnv::set(): HTTP_CONNECTION: Keep-Alive 2015-12-17 17:42:39.422637 7f88f47f0700 20 RGWEnv::set(): CONTENT_LENGTH: 1531 2015-12-17 17:42:39.422638 7f88f47f0700 20 RGWEnv::set(): REQUEST_METHOD: PUT 2015-12-17 17:42:39.422640 7f88f47f0700 20 RGWEnv::set(): REQUEST_URI: /admin/metadata/user 2015-12-17 17:42:39.422641 7f88f47f0700 20 RGWEnv::set(): QUERY_STRING: key=-staff 2015-12-17 17:42:39.422643 7f88f47f0700 20 RGWEnv::set(): REMOTE_USER: 2015-12-17 17:42:39.422644 7f88f47f0700 20 RGWEnv::set(): SCRIPT_URI: /admin/metadata/user 2015-12-17 17:42:39.422651 7f88f47f0700 20 RGWEnv::set(): SERVER_PORT: 7480 2015-12-17 17:42:39.422652 7f88f47f0700 20 CONTENT_LENGTH=1531 2015-12-17 17:42:39.422654 7f88f47f0700 20 CONTENT_TYPE=application/json 2015-12-17 17:42:39.422655 7f88f47f0700 20 HTTP_ACCEPT=*/* 2015-12-17 17:42:39.422655 7f88f47f0700 20 HTTP_ACCEPT_ENCODING=gzip, deflate 2015-12-17 17:42:39.422656 7f88f47f0700 20 HTTP_AUTHORIZATION=AWS RTJ1TL13CH613JRU2PJD:K3xaPHDy6t3r0COfjwl9rAUsUfY= 2015-12-17 17:42:39.422657 7f88f47f0700 20 HTTP_CONNECTION=Keep-Alive 2015-12-17 17:42:39.422658 7f88f47f0700 20 HTTP_DATE=Thu, 17 Dec 2015 22:42:39 GMT 2015-12-17 17:42:39.422658 7f88f47f0700 20 HTTP_HOST=localhost:7480 2015-12-17 17:42:39.422659 7f88f47f0700 20 HTTP_USER_AGENT=python-requests/2.3.0 CPython/2.7.10 Darwin/14.5.0 2015-12-17 17:42:39.422660 7f88f47f0700 20 HTTP_X_FORWARDED_FOR=192.168.86.254 2015-12-17 17:42:39.422660 7f88f47f0700 20 HTTP_X_FORWARDED_HOST=ceph.umiacs.umd.edu 2015-12-17 17:42:39.422661 7f88f47f0700 20 HTTP_X_FORWARDED_SERVER=cephproxy00.umiacs.umd.edu 2015-12-17 17:42:39.422662 7f88f47f0700 20 QUERY_STRING=key=-staff 2015-12-17 17:42:39.422662 7f88f47f0700 20 REMOTE_USER= 2015-12-17 17:42:39.422663 7f88f47f0700 20 REQUEST_METHOD=PUT 2015-12-17 17:42:39.422664 7f88f47f0700 20 REQUEST_URI=/admin/metadata/user 2015-12-17 17:42:39.422664 7f88f47f0700 20 SCRIPT_URI=/admin/metadata/user 2015-12-17 17:42:39.422665 7f88f47f0700 20 SERVER_PORT=7480 2015-12-17 17:42:39.422667 7f88f47f0700 20 RGWEnv::set(): HTTP_HOST: localhost:7480 2015-12-17 17:42:39.422668 7f88f47f0700 20 RGWEnv::set(): HTTP_ACCEPT_ENCODING: gzip, deflate 2015-12-17 17:42:39.422670 7f88f47f0700 20 RGWEnv::set(): HTTP_ACCEPT: */* 2015-12-17 17:42:39.422671 7f88f47f0700 20 RGWEnv::set(): HTTP_USER_AGENT: python-requests/2.3.0 CPython/2.7.10 Darwin/14.5.0 2015-12-17 17:42:39.422672 7f88f47f0700 20 RGWEnv::set(): HTTP_DATE: Thu, 17 Dec 2015 22:42:39 GMT 2015-12-17 17:42:39.422673 7f88f47f0700 20 RGWEnv::set(): CONTENT_TYPE: application/json 2015-12-17 17:42:39.422674 7f88f47f0700 20 RGWEnv::set(): HTTP_AUTHORIZATION: AWS RTJ1TL13CH613JRU2PJD:K3xaPHDy6t3r0COfjwl9rAUsUfY= 2015-12-17 17:42:39.422676 7f88f47f0700 20 RGWEnv::set(): HTTP_X_FORWARDED_FOR: 192.168.86.254 2015-12-17 17:42:39.422677 7f88f47f0700 20 RGWEnv::set(): HTTP_X_FORWARDED_HOST: ceph.umiacs.umd.edu 2015-12-17 17:42:39.422678 7f88f47f0700 20 RGWEnv::set(): HTTP_X_FORWARDED_SERVER: cephproxy00.umiacs.umd.edu 2015-12-17 17:42:39.422679 7f88f47f0700 20 RGWEnv::set(): HTTP_CONNECTION: Keep-Alive 2015-12-17 17:42:39.422680 7f88f47f0700 20 RGWEnv::set(): CONTENT_LENGTH: 1531 2015-12-17 17:42:39.422681 7f88f47f0700 20 RGWEnv::set(): REQUEST_METHOD: PUT 2015-12-17 17:42:39.422682 7f88f47f0700 20 RGWEnv::set(): REQUEST_URI: /admin/metadata/user 2015-12-17 17:42:39.422683 7f88f47f0700 20 RGWEnv::set(): QUERY_STRING: key=-staff 2015-12-17 17:42:39.422684 7f88f47f0700 20 RGWEnv::set(): REMOTE_USER: 2015-12-17 17:42:39.422685 7f88f47f0700 20 RGWEnv::set(): SCRIPT_URI: /admin/metadata/user 2015-12-17 17:42:39.422686 7f88f47f0700 20 RGWEnv::set(): SERVER_PORT: 7480 2015-12-17
Re: rgw subuser create and admin api
On Thu, Dec 17, 2015 at 2:44 PM, Derek Yarnellwrote: > On 12/17/15 3:15 PM, Yehuda Sadeh-Weinraub wrote: >> >> Right. Reading the code again: >> >> Try: >> GET /admin/metadata/user=cephtest > > Thanks this is very helpful and works and I was able to also get the PUT > working. Only question is that is it expected to return a 204 no content? Yes, it's expected. Yehuda > > 2015-12-17 17:42:39.422612 7f88f47f0700 20 RGWEnv::set(): HTTP_HOST: > localhost:7480 > 2015-12-17 17:42:39.422619 7f88f47f0700 20 RGWEnv::set(): > HTTP_ACCEPT_ENCODING: gzip, deflate > 2015-12-17 17:42:39.422621 7f88f47f0700 20 RGWEnv::set(): HTTP_ACCEPT: */* > 2015-12-17 17:42:39.422623 7f88f47f0700 20 RGWEnv::set(): > HTTP_USER_AGENT: python-requests/2.3.0 CPython/2.7.10 Darwin/14.5.0 > 2015-12-17 17:42:39.422625 7f88f47f0700 20 RGWEnv::set(): HTTP_DATE: > Thu, 17 Dec 2015 22:42:39 GMT > 2015-12-17 17:42:39.422627 7f88f47f0700 20 RGWEnv::set(): CONTENT_TYPE: > application/json > 2015-12-17 17:42:39.422629 7f88f47f0700 20 RGWEnv::set(): > HTTP_AUTHORIZATION: AWS RTJ1TL13CH613JRU2PJD:K3xaPHDy6t3r0COfjwl9rAUsUfY= > 2015-12-17 17:42:39.422630 7f88f47f0700 20 RGWEnv::set(): > HTTP_X_FORWARDED_FOR: 192.168.86.254 > 2015-12-17 17:42:39.422632 7f88f47f0700 20 RGWEnv::set(): > HTTP_X_FORWARDED_HOST: ceph.umiacs.umd.edu > 2015-12-17 17:42:39.422634 7f88f47f0700 20 RGWEnv::set(): > HTTP_X_FORWARDED_SERVER: cephproxy00.umiacs.umd.edu > 2015-12-17 17:42:39.422636 7f88f47f0700 20 RGWEnv::set(): > HTTP_CONNECTION: Keep-Alive > 2015-12-17 17:42:39.422637 7f88f47f0700 20 RGWEnv::set(): > CONTENT_LENGTH: 1531 > 2015-12-17 17:42:39.422638 7f88f47f0700 20 RGWEnv::set(): > REQUEST_METHOD: PUT > 2015-12-17 17:42:39.422640 7f88f47f0700 20 RGWEnv::set(): REQUEST_URI: > /admin/metadata/user > 2015-12-17 17:42:39.422641 7f88f47f0700 20 RGWEnv::set(): QUERY_STRING: > key=-staff > 2015-12-17 17:42:39.422643 7f88f47f0700 20 RGWEnv::set(): REMOTE_USER: > 2015-12-17 17:42:39.422644 7f88f47f0700 20 RGWEnv::set(): SCRIPT_URI: > /admin/metadata/user > 2015-12-17 17:42:39.422651 7f88f47f0700 20 RGWEnv::set(): SERVER_PORT: 7480 > 2015-12-17 17:42:39.422652 7f88f47f0700 20 CONTENT_LENGTH=1531 > 2015-12-17 17:42:39.422654 7f88f47f0700 20 CONTENT_TYPE=application/json > 2015-12-17 17:42:39.422655 7f88f47f0700 20 HTTP_ACCEPT=*/* > 2015-12-17 17:42:39.422655 7f88f47f0700 20 HTTP_ACCEPT_ENCODING=gzip, > deflate > 2015-12-17 17:42:39.422656 7f88f47f0700 20 HTTP_AUTHORIZATION=AWS > RTJ1TL13CH613JRU2PJD:K3xaPHDy6t3r0COfjwl9rAUsUfY= > 2015-12-17 17:42:39.422657 7f88f47f0700 20 HTTP_CONNECTION=Keep-Alive > 2015-12-17 17:42:39.422658 7f88f47f0700 20 HTTP_DATE=Thu, 17 Dec 2015 > 22:42:39 GMT > 2015-12-17 17:42:39.422658 7f88f47f0700 20 HTTP_HOST=localhost:7480 > 2015-12-17 17:42:39.422659 7f88f47f0700 20 > HTTP_USER_AGENT=python-requests/2.3.0 CPython/2.7.10 Darwin/14.5.0 > 2015-12-17 17:42:39.422660 7f88f47f0700 20 > HTTP_X_FORWARDED_FOR=192.168.86.254 > 2015-12-17 17:42:39.422660 7f88f47f0700 20 > HTTP_X_FORWARDED_HOST=ceph.umiacs.umd.edu > 2015-12-17 17:42:39.422661 7f88f47f0700 20 > HTTP_X_FORWARDED_SERVER=cephproxy00.umiacs.umd.edu > 2015-12-17 17:42:39.422662 7f88f47f0700 20 QUERY_STRING=key=-staff > 2015-12-17 17:42:39.422662 7f88f47f0700 20 REMOTE_USER= > 2015-12-17 17:42:39.422663 7f88f47f0700 20 REQUEST_METHOD=PUT > 2015-12-17 17:42:39.422664 7f88f47f0700 20 REQUEST_URI=/admin/metadata/user > 2015-12-17 17:42:39.422664 7f88f47f0700 20 SCRIPT_URI=/admin/metadata/user > 2015-12-17 17:42:39.422665 7f88f47f0700 20 SERVER_PORT=7480 > 2015-12-17 17:42:39.422667 7f88f47f0700 20 RGWEnv::set(): HTTP_HOST: > localhost:7480 > 2015-12-17 17:42:39.422668 7f88f47f0700 20 RGWEnv::set(): > HTTP_ACCEPT_ENCODING: gzip, deflate > 2015-12-17 17:42:39.422670 7f88f47f0700 20 RGWEnv::set(): HTTP_ACCEPT: */* > 2015-12-17 17:42:39.422671 7f88f47f0700 20 RGWEnv::set(): > HTTP_USER_AGENT: python-requests/2.3.0 CPython/2.7.10 Darwin/14.5.0 > 2015-12-17 17:42:39.422672 7f88f47f0700 20 RGWEnv::set(): HTTP_DATE: > Thu, 17 Dec 2015 22:42:39 GMT > 2015-12-17 17:42:39.422673 7f88f47f0700 20 RGWEnv::set(): CONTENT_TYPE: > application/json > 2015-12-17 17:42:39.422674 7f88f47f0700 20 RGWEnv::set(): > HTTP_AUTHORIZATION: AWS RTJ1TL13CH613JRU2PJD:K3xaPHDy6t3r0COfjwl9rAUsUfY= > 2015-12-17 17:42:39.422676 7f88f47f0700 20 RGWEnv::set(): > HTTP_X_FORWARDED_FOR: 192.168.86.254 > 2015-12-17 17:42:39.422677 7f88f47f0700 20 RGWEnv::set(): > HTTP_X_FORWARDED_HOST: ceph.umiacs.umd.edu > 2015-12-17 17:42:39.422678 7f88f47f0700 20 RGWEnv::set(): > HTTP_X_FORWARDED_SERVER: cephproxy00.umiacs.umd.edu > 2015-12-17 17:42:39.422679 7f88f47f0700 20 RGWEnv::set(): > HTTP_CONNECTION: Keep-Alive > 2015-12-17 17:42:39.422680 7f88f47f0700 20 RGWEnv::set(): > CONTENT_LENGTH: 1531 > 2015-12-17 17:42:39.422681 7f88f47f0700 20 RGWEnv::set(): > REQUEST_METHOD: PUT > 2015-12-17 17:42:39.422682 7f88f47f0700 20 RGWEnv::set(): REQUEST_URI: > /admin/metadata/user > 2015-12-17 17:42:39.422683 7f88f47f0700 20