summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorzhihui wu <wu.zhihui1@zte.com.cn>2017-08-16 03:54:21 +0000
committerGerrit Code Review <gerrit@opnfv.org>2017-08-16 03:54:22 +0000
commite019b668eecbec276999c1399ba673eaa3aad968 (patch)
treedb28730268265f4fc14d5a2675739d98dac27e62
parent7f9a8986daa417e05b55c6c9c52719ce1e060b18 (diff)
parent00f4c00451915852ce20b2980e1024e1dd6ef45d (diff)
Merge "Fix permission issue on apex"
-rw-r--r--resources/ansible_roles/ceph-disk-info/tasks/main.yml9
1 files changed, 6 insertions, 3 deletions
diff --git a/resources/ansible_roles/ceph-disk-info/tasks/main.yml b/resources/ansible_roles/ceph-disk-info/tasks/main.yml
index 3186e3dd..6bb88e69 100644
--- a/resources/ansible_roles/ceph-disk-info/tasks/main.yml
+++ b/resources/ansible_roles/ceph-disk-info/tasks/main.yml
@@ -8,8 +8,9 @@
##############################################################################
-- name: get ceph disk information
- shell: ceph-disk list
+- name: get ceph disk information
+ become: true
+ command: ceph-disk list
register: ceph_disk_out
- name: saving output to log
@@ -19,10 +20,11 @@
delegate_to: localhost
- name: get ceph journal information
+ become: true
shell: lsblk -d -o name,rota |awk '{if ($2 == 0) printf "%s SSD \n",$1 }'
register: ceph_journal_out
-- name: append
+- name: append
lineinfile:
dest: "{{ logfile }}"
line: "{{ ceph_journal_out.stdout }}"
@@ -30,6 +32,7 @@
delegate_to: localhost
- name: get ceph report
+ become: true
command: ceph report
register: ceph_report_out