summaryrefslogtreecommitdiffstats
path: root/roles/ands_vagrant_vmconf/tasks/main.yml
blob: b130aa48249dd23a3e6d23273256b9d5b98a8d15 (plain)
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
 - name: Get partition info
   parted: device="/dev/sda" unit="MiB"
   register: partinfo

 - set_fact: parts="{{partinfo.partitions | length}}"
 - set_fact: end="{{partinfo.partitions[(parts | int) - 1].end | round | int}}"

 - name: Add partition to the first disk
   parted: device="/dev/sda" number=4 part_start="{{ end }}MiB" flags="lvm" state="present"

 - name: Resize Root VG
   lvg: vg="VolGroup00" pvs="/dev/sda3,/dev/sda4"

 - name: Resize Root LV
   lvol: vg="VolGroup00" lv="LogVol00" size="+100%FREE"

 - name: Resize FS
   filesystem: dev="/dev/mapper/VolGroup00-LogVol00" fstype="xfs" resizefs="yes"

 - name: Create required directories
   file: path="/etc/origin/node/" state="directory"
 
# We just need networkmanager running   
# - name: Bypass absent NM
#   copy: remote_src="yes" src="/etc/resolv.conf" dest="/etc/origin/node/resolv.conf"