]> git.apps.os.sepia.ceph.com Git - ceph-ansible.git/commitdiff
NFS fixups 941/head
authorDaniel Gryniewicz <dang@redhat.com>
Thu, 18 Aug 2016 12:24:48 +0000 (08:24 -0400)
committerDaniel Gryniewicz <dang@redhat.com>
Thu, 18 Aug 2016 16:25:20 +0000 (12:25 -0400)
- Move fsal_rgw config to ceph-common, as it's shaered with ceph-rgw
- Update all.docker.sample with NFS config
- Rename fsal_rgw to nfs_obj_gw and fsal_ceph to nfs_file_gw, because
  the former names mean nothing to non-Ganesha developers

Signed-off-by: Daniel Gryniewicz <dang@redhat.com>
group_vars/all.docker.sample
group_vars/all.sample
group_vars/nfss.sample
roles/ceph-common/defaults/main.yml
roles/ceph-common/tasks/installs/install_on_redhat.yml
roles/ceph-common/templates/ganesha.conf.j2
roles/ceph-nfs/defaults/main.yml
roles/ceph-nfs/tasks/docker/create_configs.yml
roles/ceph-nfs/tasks/pre_requisite.yml
roles/ceph-rgw/tasks/docker/copy_configs.yml

index 48cf7066ac0fc8133cfa00f75e1895af6e8100b3..c30b8f40340663952f774ec99935ad7e5b3f1349 100644 (file)
@@ -89,3 +89,16 @@ dummy:
 #ceph_rbd_mirror_docker_image_tag: latest
 #ceph_docker_on_openstack: false
 
+#######
+# NFS #
+#######
+#nfs_containerized_deployment: true
+#nfs_containerized_deployment_with_kv: false
+#ceph_nfs_docker_username: ceph
+#ceph_nfs_docker_imagename: daemon
+#ceph_nfs_docker_image_tag: latest
+#ceph_nfs_docker_extra_env: "GANESHA_EPOCH={{ ganesha_epoch }}" # comma separated variables
+#nfs_file_gw: false
+#nfs_obj_gw: false
+#ceph_nfs_rgw_access_key: "QFAMEDSJP5DEKJO0DDXY"
+#ceph_nfs_rgw_secret_key: "iaSFLDVvDdQt6lkNzHyW4fPLZugBAI1g17LO0+87[MAC[M#C"
index 0779a62696ce258b98483f5781f8a87f490e7a29..c585b840a0b1258c678a0e5fa8944dce2360fc33 100644 (file)
@@ -84,7 +84,7 @@ dummy:
 
 ## Configure package origin
 #
-#ceph_origin: 'upstream' #'distro' or 'local'
+#ceph_origin: 'upstream' # or 'distro' or 'local'
 # 'distro' means that no separate repo file will be added
 # you will get whatever version of Ceph is included in your Linux distro.
 # 'local' means that the ceph binaries will be copied over from the local machine
@@ -369,3 +369,11 @@ dummy:
 
 #osd_auto_discovery: False
 
+# Confiure the type of NFS gatway access.  At least one must be enabled for an
+# NFS role to be useful
+#
+# Set this to true to enable File access via NFS.  Requires an MDS role.
+#nfs_file_gw: true
+# Set this to true to enable Object access via NFS. Requires an RGW role.
+#nfs_obj_gw: false
+
index 02794946862c404f086ad01e8d9fe2a435b4b3d3..e0942cb92508379bfbe934eb3dbde1dde098fd69 100644 (file)
@@ -22,17 +22,17 @@ dummy:
 #######################
 # Access type options #
 #######################
+# These are currently in ceph-common defaults because nfs_obj_gw shared with ceph-rgw
 # Enable NFS File access
-#fsal_ceph: true
-
+#nfs_file_gw: true
 # Enable NFS Object access
-#fsal_rgw: false
+#nfs_obj_gw: false
 
 ######################
 # NFS Ganesha Config #
 ######################
 #ceph_nfs_export_id: 20134
-#ceph_nfs_pseudo_path: "/ceph"
+#ceph_nfs_pseudo_path: "/cephfile"
 #ceph_nfs_protocols: "3,4"
 #ceph_nfs_access_type: "RW"
 #ceph_nfs_log_file: "/var/log/ganesha.log"
@@ -41,7 +41,7 @@ dummy:
 # FSAL Ceph Config #
 ####################
 #ceph_nfs_ceph_export_id: 20134
-#ceph_nfs_ceph_pseudo_path: "/ceph"
+#ceph_nfs_ceph_pseudo_path: "/cephobject"
 #ceph_nfs_ceph_protocols: "3,4"
 #ceph_nfs_ceph_access_type: "RW"
 
index 3f6dc4ccd78a8b9d793bb01faaffa7524243b031..3e4cc259e5376218c2299bfabd6def9d1f357173 100644 (file)
@@ -360,3 +360,11 @@ dmcrypt_journal_collocation: False
 dmcrypt_dedicated_journal: False
 
 osd_auto_discovery: False
+
+# Confiure the type of NFS gatway access.  At least one must be enabled for an
+# NFS role to be useful
+#
+# Set this to true to enable File access via NFS.  Requires an MDS role.
+nfs_file_gw: true
+# Set this to true to enable Object access via NFS. Requires an RGW role.
+nfs_obj_gw: false
index 528358832e545f00b0d12256403970c1fcfdf428..b3561fdbccb0b6ee623477457928995770da578a 100644 (file)
   when:
     - nfs_group_name in group_names
     - ansible_pkg_mgr == "yum"
-    - fsal_ceph
+    - nfs_file_gw
 
 - name: install nfs ceph gateway
   dnf:
   when:
     - nfs_group_name in group_names
     - ansible_pkg_mgr == "dnf"
-    - fsal_ceph
+    - nfs_file_gw
 
 - name: install nfs rgw gateway
   yum:
   when:
     - nfs_group_name in group_names
     - ansible_pkg_mgr == "yum"
-    - fsal_rgw
+    - nfs_obj_gw
 
 - name: install nfs rgw gateway
   dnf:
   when:
     - nfs_group_name in group_names
     - ansible_pkg_mgr == "dnf"
-    - fsal_rgw
+    - nfs_obj_gw
index 38bb67b0b04885a98e6e1728e008f26fcc76df30..0c661b3d33804f5b7c15e23d3291ed3a84965abe 100644 (file)
@@ -1,7 +1,7 @@
 #jinja2: trim_blocks: "true", lstrip_blocks: "true"
 # {{ ansible_managed }}
 
-{% if fsal_ceph %}
+{% if nfs_file_gw %}
 EXPORT
 {
        Export_ID={{ ceph_nfs_ceph_export_id }};
@@ -23,7 +23,7 @@ EXPORT
        }
 }
 {% endif %}
-{% if fsal_rgw %}
+{% if nfs_obj_gw %}
 EXPORT
 {
        Export_ID={{ ceph_nfs_rgw_export_id }};
index 2848361ef77a349507753f53e2f61ce7b2983d1a..f4b82f316e92b19f5b830c25339f1969b3e48c1e 100644 (file)
@@ -14,17 +14,17 @@ cephx: true
 #######################
 # Access type options #
 #######################
+# These are currently in ceph-common defaults because nfs_obj_gw shared with ceph-rgw
 # Enable NFS File access
-fsal_ceph: true
-
+#nfs_file_gw: true
 # Enable NFS Object access
-fsal_rgw: false
+#nfs_obj_gw: false
 
 ######################
 # NFS Ganesha Config #
 ######################
 ceph_nfs_export_id: 20134
-ceph_nfs_pseudo_path: "/ceph"
+ceph_nfs_pseudo_path: "/cephfile"
 ceph_nfs_protocols: "3,4"
 ceph_nfs_access_type: "RW"
 ceph_nfs_log_file: "/var/log/ganesha.log"
@@ -33,7 +33,7 @@ ceph_nfs_log_file: "/var/log/ganesha.log"
 # FSAL Ceph Config #
 ####################
 ceph_nfs_ceph_export_id: 20134
-ceph_nfs_ceph_pseudo_path: "/ceph"
+ceph_nfs_ceph_pseudo_path: "/cephobject"
 ceph_nfs_ceph_protocols: "3,4"
 ceph_nfs_ceph_access_type: "RW"
 
index 560ff20fc60a01a8a750de0ca94b6624a4081a3a..1bbd65733f318d21d87d6d86df395da4c24f8807 100644 (file)
@@ -16,7 +16,7 @@
     state: running
     env: "CEPH_DAEMON=RGW_USER,RGW_USERNAME={{ ceph_nfs_rgw_user }},RGW_USER_ACCESS_KEY={{ ceph_nfs_rgw_access_key }},RGW_USER_SECRET_KEY={{ ceph_nfs_rgw_secret_key }}"
     volumes: "/var/lib/ceph:/var/lib/ceph,/etc/ceph:/etc/ceph"
-  when: fsal_rgw
+  when: nfs_obj_gw
 
 - name: get user create output
   command: docker logs ceph-{{ ansible_hostname }}-rgw-user
index 695f93cab4376595616abbc4dc7c1811e0848a00..adb5ec4264cd0440c72e8a6e31654aeca290a08f 100644 (file)
 - name: create rgw nfs user
   command: radosgw-admin user create --uid={{ ceph_nfs_rgw_user }} --display-name="RGW NFS User"
   register: rgwuser
-  when: fsal_rgw
+  when: nfs_obj_gw
 
 - name: set access key
   set_fact:
     ceph_nfs_rgw_access_key: "{{ (rgwuser.stdout | from_json)['keys'][0]['access_key'] }}"
-  when: fsal_rgw
+  when: nfs_obj_gw
 
 - name: set secret key
   set_fact:
     ceph_nfs_rgw_secret_key: "{{(rgwuser.stdout | from_json)['keys'][0]['secret_key']}}"
-  when: fsal_rgw
+  when: nfs_obj_gw
 
 - name: generate ganesha configuration file
   action: config_template
index 3345f1803a767563a17e50a5903aacf15443b57b..b63866e002cf71f455ade303f138678db79d6ee1 100644 (file)
@@ -3,12 +3,12 @@
   set_fact:
     rgw_config_keys:
       - "/var/lib/ceph/radosgw/{{ ansible_hostname }}/keyring"
-  when: fsal_rgw
+  when: nfs_obj_gw
 
 - name: wait for rgw keyring
   wait_for: path="/var/lib/ceph/radosgw/{{ ansible_hostname }}/keyring"
   when:
-    - fsal_rgw
+    - nfs_obj_gw
     - inventory_hostname == groups.rgws[0]
 
 - name: stat for config and keys
@@ -19,7 +19,7 @@
   failed_when: false
   register: statconfig
   when:
-    - fsal_rgw
+    - nfs_obj_gw
     - inventory_hostname == groups.rgws[0]
 
 - name: push ceph files to the ansible server
@@ -32,5 +32,5 @@
     - statconfig.results
   when:
     - item.1.stat.exists == false
-    - fsal_rgw
+    - nfs_obj_gw
     - inventory_hostname == groups.rgws[0]