Format SwiftRawDisks before attempting to mount

Current play only attempts to mount the disk and does not actually
format it for Swift usage.

Change-Id: I8e47b977407491faa71bb196211eeccf21357c54
This commit is contained in:
akrzos 2017-10-30 15:54:13 -04:00 committed by Emilien Macchi
parent 2b903d3225
commit 93adbba5f5
1 changed files with 18 additions and 1 deletions

View File

@ -436,7 +436,24 @@ outputs:
src: /var/log/swift
dest: /var/log/containers/swift
state: link
- name: Format and mount devices defined in SwiftRawDisks
- name: swift logs readme
copy:
dest: /var/log/swift/readme.txt
content: |
Log files from swift containers can be found under
/var/log/containers/swift and /var/log/containers/httpd/swift-*.
ignore_errors: true
- name: Format SwiftRawDisks
filesystem:
fstype: xfs
dev: /dev/{{ item }}
opts: -f -i size=1024
with_items:
- repeat:
template: 'DEVICE'
for_each:
DEVICE: {get_param: SwiftRawDisks}
- name: Mount devices defined in SwiftRawDisks
mount:
name: /srv/node/{{ item }}
src: /dev/{{ item }}