blob: 006e7b8955e1886797b04961c0fe10d891128af4 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
|
---
- name: create lvm device
vars:
lvm_device: "{{ lvm_volume }}"
include_role:
name: storage/lvm/device
- name: create filesystem
filesystem:
dev: "{{ storage_device_path }}"
fstype: "{{ lvm_volume.fs }}"
- name: mount filesytem
mount:
src: "{{ storage_device_path }}"
path: "{{ lvm_volume.dest }}"
fstype: "{{ lvm_volume.fs }}"
opts: "{{ lvm_volume.mntopts | default(omit) }}"
state: mounted
- name: set volume owner/group and mode
file:
state: directory
path: "{{ lvm_volume.dest }}"
mode: "{{ lvm_volume.mode | default(omit) }}"
owner: "{{ lvm_volume.owner | default(omit) }}"
group: "{{ lvm_volume.group | default(omit) }}"
- name: export volume mountpoint
set_fact:
storage_volume_mountpoint: "{{ lvm_volume.dest }}"
|