diff options
author | Sage Weil <sage@inktank.com> | 2012-12-12 08:01:49 -0800 |
---|---|---|
committer | Sage Weil <sage@inktank.com> | 2012-12-12 21:14:38 -0800 |
commit | ae100cfdbcedb1b47712d74af663dd617c0fd646 (patch) | |
tree | 8d95edbd5fb11647f3829a5f2cb2edc53a3e152a | |
parent | ac92e4d6bd453ffc77e88ab3ec2d2015b70ba854 (diff) | |
download | ceph-ae100cfdbcedb1b47712d74af663dd617c0fd646.tar.gz |
mount.fuse.ceph: add ceph-fuse mount helper
Signed-off-by: Sage Weil <sage@inktank.com>
-rw-r--r-- | ceph.spec.in | 1 | ||||
-rw-r--r-- | debian/ceph-fuse.install | 1 | ||||
-rw-r--r-- | src/Makefile.am | 6 | ||||
-rwxr-xr-x | src/mount.fuse.ceph | 20 |
4 files changed, 26 insertions, 2 deletions
diff --git a/ceph.spec.in b/ceph.spec.in index 3a369cf5359..ba1cce459bc 100644 --- a/ceph.spec.in +++ b/ceph.spec.in @@ -356,6 +356,7 @@ fi %defattr(-,root,root,-) %{_bindir}/ceph-fuse %{_mandir}/man8/ceph-fuse.8* +/sbin/mount.fuse.ceph ################################################################################# %files devel diff --git a/debian/ceph-fuse.install b/debian/ceph-fuse.install index b8dd3b32d63..79588d2a629 100644 --- a/debian/ceph-fuse.install +++ b/debian/ceph-fuse.install @@ -1,2 +1,3 @@ usr/bin/ceph-fuse usr/share/man/man8/ceph-fuse.8 +sbin/mount.fuse.ceph diff --git a/src/Makefile.am b/src/Makefile.am index 64924d7bd50..2a874e71635 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -29,7 +29,8 @@ sbin_PROGRAMS = sbin_SCRIPTS = \ ceph-disk-prepare \ ceph-disk-activate \ - ceph-create-keys + ceph-create-keys \ + mount.fuse.ceph bin_SCRIPTS = ceph-run $(srcdir)/ceph-clsinfo ceph-debugpack ceph-rbdnamer dist_bin_SCRIPTS = # C/C++ tests to build will be appended to this @@ -1097,7 +1098,8 @@ EXTRA_DIST += \ $(srcdir)/upstart/radosgw-all-starter.conf \ ceph-disk-prepare \ ceph-disk-activate \ - ceph-create-keys + ceph-create-keys \ + mount.fuse.ceph EXTRA_DIST += $(srcdir)/$(shell_scripts:%=%.in) diff --git a/src/mount.fuse.ceph b/src/mount.fuse.ceph new file mode 100755 index 00000000000..f579953981a --- /dev/null +++ b/src/mount.fuse.ceph @@ -0,0 +1,20 @@ +#!/bin/sh +# +# Helper to mount ceph-fuse from /etc/fstab. To use, add an entry +# like: +# +# # DEVICE PATH TYPE OPTIONS +# id=admin /mnt/ceph fuse.ceph defaults 0 0 +# id=myuser,conf=/etc/ceph/foo.conf /mnt/ceph2 fuse.ceph defaults 0 0 +# +# where the device field is a comma-separated list of options to pass on +# the command line. The examples above, for example, specify that +# ceph-fuse will authenticated as client.admin and client.myuser +# (respectively), and the second example also sets the 'conf' option to +# '/etc/ceph/foo.conf' via the ceph-fuse command line. Any valid +# ceph-fuse can be passed in this way. + +set -e +options='--'`echo $1 | sed 's/,/ --/g'` +shift +exec ceph-fuse $options $@ |