Commit Graph

14 Commits

Author SHA1 Message Date
John Spray
c7e905e7e2 ceph-create-keys: set mds "allow *"
So that 'tell' works out of the box.

Signed-off-by: John Spray <john.spray@redhat.com>
2015-09-25 16:09:00 +01:00
Milan Broz
52e978e4b3 Set keys owner to ceph user if exists.
Also fix directory access rigths.

Signed-off-by: Milan Broz <mbroz@redhat.com>
2015-08-26 20:34:15 -04:00
Sage Weil
f5fa25d50f ceph-create-keys: create bootstrap-rgw key
Signed-off-by: Sage Weil <sage@redhat.com>
2015-03-17 16:16:01 -07:00
Dan Mick
b9000b314b Invoke python with /usr/bin/env python instead of directly
Fixes: #6311
Signed-off-by: Dan Mick <dan.mick@inktank.com>
2013-09-30 14:58:11 -07:00
Peter Wienemann
1577e203f0 ceph-create-keys: Make sure directories for admin and bootstrap keys exist
Signed-off-by: Peter Wienemann <wienemann@physik.uni-bonn.de>
2013-06-12 08:40:25 -07:00
Gary Lowell
0948624f3e ceph-create-keys: Remove unused caps parameter on bootstrap_key()
The caps parameter was removed except for one place.

Signed-off-by: Gary Lowell  <gary.lowell@inktank.com>
2013-06-11 08:25:36 -07:00
Sage Weil
1123fc293f mon/MonCap: add new MonCap implementation
This is a new class with a new grammer.  Implementation is modeled after
OSDCap, and the semantics are based on the old MonCaps, although somewhat
different (though not in too many important ways, I think).

Note that we complete drop auid support; the semantics for that were a
complete mess.

Signed-off-by: Sage Weil <sage@inktank.com>
2013-05-21 16:23:43 -07:00
Sage Weil
e2528ae42c ceph-create-keys: gracefully handle no data from admin socket
Old ceph-mon (prior to 393c9372f8) would
return an empty string and success if the command was not registered yet.
Gracefully handle that case by retrying.

If we still fail to parse, exit entirely with EINVAL.

Fixes: #4952
Signed-off-by: Sage Weil <sage@inktank.com>
Reviewed-by: Dan Mick <dan.mick@intank.com>
2013-05-08 14:54:33 -07:00
Gary Lowell
1a8b30eff1 ceph-create-keys: Don't wait if permission denied
If get or create keys returns permssion denied, exit
gracefully instead of retrying.

Signed-off-by: Gary Lowell  <gary.lowell@inktank.com>
Reviewed-by: Sage Weil <sage@inktank.com>
2013-04-21 22:08:49 -07:00
Danny Al-Gaaf
e2df59e245 ceph-create-keys: rename log to LOG since it's a constants
Signed-off-by: Danny Al-Gaaf <danny.al-gaaf@bisect.de>
2013-03-21 17:13:26 +01:00
Sage Weil
809143f16c ceph-create-keys: create mds bootstrap key
Signed-off-by: Sage Weil <sage@inktank.com>
2013-02-13 12:30:22 -08:00
Tommi Virtanen
1f3a50a521 ceph-create-keys: Refactor to share wait_for_quorum call.
Signed-off-by: Tommi Virtanen <tv@inktank.com>
2012-10-05 11:09:06 -07:00
Tommi Virtanen
4302f12a60 ceph-create-keys: Create a bootstrap-osd key too.
Signed-off-by: Tommi Virtanen <tv@inktank.com>
2012-10-05 11:09:06 -07:00
Tommi Virtanen
f2c4510848 upstart, ceph-create-keys: Make client.admin key generation automatic.
This should help simplify Chef etc deployments. Now (when using the
Upstart jobs), when a ceph-mon is started, ceph-create-admin-key is
triggered. If /etc/ceph/$cluster.client.admin.keyring already exists,
it does nothing; otherwise, it waits for ceph-mon to reach quorum, and
then does a "ceph auth get-or-create" to create the key, and writes it
atomically to disk.

The equivalent code can be removed from the Chef cookbook once this is
in.
2012-08-30 13:41:20 -04:00