Ansible playbooks to deploy Ceph, the distributed filesystem.
 
 
 
 
Go to file
John Fulton d65cbaa539 Set permissions and ACLs of OpenStack keys on all ceph-mons
If ceph-ansible deploys a Ceph cluster with "openstack_config: true"
and sets the openstack_keys map to have certain ACLs or permissions,
the requested ACLs or permissions are only set on one of the monitor
nodes [2] when they should be set on all of them.

This patch solves [3] the above issue by having the chmod and setfacl
tasks iterate the list of mon nodes (including the mon node that the
task was delegated to) to apply the chmod of setfacl to the keys in
openstack_keys.

[1]
```
openstack_keys:
  - { name: client.openstack, key: "$(ceph-authtool --gen-print-key)", mon_cap: "allow r", osd_cap: "allow class-read object_prefix rbd_children, allow rwx pool=images, allow rwx pool=vms, allow rwx pool=volumes, allow rwx pool=backups", mode: "0600", acls: ["u:nova:r--", "u:cinder:r--", "u:glance:r--", "u:gnocchi:r--"] }
```
[2]
```
$ ansible mons -m shell -b -a "ls -l /etc/ceph/ceph.client.openstack.keyring ; getfacl /etc/ceph/ceph.client.openstack.keyring"
192.168.1.26 | SUCCESS | rc=0 >>
-rw-r-----+ 1 root root 253 Nov  3 20:30 /etc/ceph/ceph.client.openstack.keyring
user::rw-
user:glance:r--
user:nova:r--
user:cinder:r--
user:gnocchi:r--
group::---
mask::r--
other::---getfacl: Removing leading '/' from absolute path names

192.168.1.29 | SUCCESS | rc=0 >>
-rw-r--r--. 1 root root 253 Nov  3 20:30 /etc/ceph/ceph.client.openstack.keyring
user::rw-
group::r--
other::r--getfacl: Removing leading '/' from absolute path names

192.168.1.23 | SUCCESS | rc=0 >>
-rw-r--r--. 1 root root 253 Nov  3 20:30 /etc/ceph/ceph.client.openstack.keyring
user::rw-
group::r--
other::r--getfacl: Removing leading '/' from absolute path names

$
```
[3]
```
(undercloud) [stack@hci-director ceph-ansible]$ ansible mons -m shell -b -a "ls -l /etc/ceph/ceph.client.openstack.keyring ; getfacl /etc/ceph/ceph.client.openstack.keyring"
192.168.1.25 | SUCCESS | rc=0 >>
-rw-r-----+ 1 root root 253 Nov 14 01:12 /etc/ceph/ceph.client.openstack.keyring
user::rw-
user:glance:r--
user:nova:r--
user:cinder:r--
user:gnocchi:r--
group::---
mask::r--
other::---getfacl: Removing leading '/' from absolute path names

192.168.1.29 | SUCCESS | rc=0 >>
-rw-r-----+ 1 root root 253 Nov 14 01:12 /etc/ceph/ceph.client.openstack.keyring
user::rw-
user:glance:r--
user:nova:r--
user:cinder:r--
user:gnocchi:r--
group::---
mask::r--
other::---getfacl: Removing leading '/' from absolute path names

192.168.1.27 | SUCCESS | rc=0 >>
-rw-r-----+ 1 root root 253 Nov 14 01:12 /etc/ceph/ceph.client.openstack.keyring
user::rw-
user:glance:r--
user:nova:r--
user:cinder:r--
user:gnocchi:r--
group::---
mask::r--
other::---getfacl: Removing leading '/' from absolute path names

(undercloud) [stack@hci-director ceph-ansible]$
```
2017-11-15 10:09:24 -05:00
contrib contrib: skip ci and hightlight origin PR 2017-10-31 14:43:29 +01:00
docker docker: add README documenting directory purpose 2016-09-21 18:21:50 -04:00
docs fix the ansible version for the stable-3.0 branch 2017-11-06 16:15:47 +08:00
group_vars osd: fix a typo in roles/ceph-osd/defaults/main.yml 2017-11-07 10:06:16 +01:00
infrastructure-playbooks Merge pull request #2142 from squidboylan/master 2017-11-13 22:06:16 +11:00
library resync ceph-iscsi-gw with old upstream 2017-09-12 18:06:10 -06:00
plugins/actions ceph-defaults: fix handlers that are always triggered 2017-10-13 16:15:27 +02:00
profiles Common: Add profiles 2017-07-19 11:50:03 +02:00
roles Set permissions and ACLs of OpenStack keys on all ceph-mons 2017-11-15 10:09:24 -05:00
tests tests: remove OSD_FORCE_ZAP variable from tests 2017-11-14 17:55:01 +01:00
.gitignore common: do not run tasks in main.yml, use include 2016-12-09 16:00:46 +01:00
LICENSE Add Ceph Playbook 2014-03-03 19:08:51 +01:00
Makefile Makefile: remove fedpkg dependency for "srpm" 2017-09-13 10:46:37 -06:00
README-MULTISITE.md Experimental RGW Multisite Support 2016-08-16 14:57:01 -04:00
README.rst docs: remove the old README and link to the hosted docs 2017-08-17 16:03:04 -05:00
Vagrantfile ci: disable vnc console 2017-10-09 17:25:45 +02:00
action_plugins Adding symlink to action_plugins so this works in ansible tower 2016-12-12 10:57:51 -05:00
ansible.cfg ansible.cfg: increase ssh timeout 2017-09-06 11:26:36 +02:00
ceph-aio-no-vagrant.sh osd: simplify scenarios 2017-08-03 10:20:39 +02:00
ceph-ansible.spec.in rpm: require ansible 2.4.1.0 2017-11-10 10:11:31 -07:00
dummy-ansible-hosts Fix Travis 2015-01-21 16:33:26 +01:00
example-ansible-role-requirements.yml add a galaxy dependency file example 2016-02-12 15:55:42 +01:00
generate_group_vars_sample.sh generate_group_vars_sample: rhcs.yml.sample 2017-08-03 23:05:42 +02:00
monitor_keys_example Add Monitor Keys example 2015-01-30 16:17:46 +01:00
rhcs_edits.txt common: refactor installation method 2017-08-30 10:52:01 +02:00
rundep.sample Allow ceph-ansible to be run on a locally built/installed Ceph 2016-08-12 10:02:15 -04:00
rundep_installer.sh Allow ceph-ansible to be run on a locally built/installed Ceph 2016-08-12 10:02:15 -04:00
site-docker.yml.sample site-docker.yml try to fetch images in // 2017-10-13 11:24:40 +02:00
site.yml.sample common: make the delegate_facts feature optional 2017-10-31 16:44:26 +01:00
test.yml remove rbd-mirror as well from testing. No packages are available yet 2016-04-12 07:38:13 -04:00
tox.ini tests: set CEPH_STABLE_RELEASE in ceph-build 2017-11-14 13:39:54 +01:00
vagrant_variables.yml.atomic vagrantfile: Ensure `devices` variable is a list 2017-07-13 00:44:49 +02:00
vagrant_variables.yml.linode vagrant: use group_vars for ceph pkg source 2016-10-21 10:46:11 -04:00
vagrant_variables.yml.openstack vagrantfile: Ensure `devices` variable is a list 2017-07-13 00:44:49 +02:00
vagrant_variables.yml.sample vagrantfile: Ensure `devices` variable is a list 2017-07-13 00:44:49 +02:00

README.rst

ceph-ansible
============
Ansible playbooks for Ceph, the distributed filesystem.

Please refer to our hosted documentation here: http://docs.ceph.com/ceph-ansible/master/

You can view documentation for our ``stable-*`` branches by substituting ``master`` in the link
above for the name of the branch. For example: http://docs.ceph.com/ceph-ansible/stable-2.2/