summaryrefslogtreecommitdiffstats
path: root/playbooks/aws/openshift-cluster/templates/user_data.j2
blob: b7d89eac155b816031880f82f4f64cd3c3993a42 (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
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
#cloud-config
{% if type =='etcd' %}
cloud_config_modules:
- disk_setup
- mounts

mounts:
- [ xvdb, /var/lib/etcd, xfs, "defaults" ]

disk_setup:
  xvdb:
    table_type: mbr
    layout: True

fs_setup:
- label: etcd_storage
  filesystem: xfs
  device: /dev/xvdb
  partition: auto
{% endif %}

{% if type == 'node' or type == 'master' %}
mounts:
- [ xvdb ]
- [ ephemeral0 ]

write_files:
- content: |
    DEVS=/dev/xvdb
    VG=docker_vg
  path: /etc/sysconfig/docker-storage-setup
  owner: root:root
  permissions: '0644'
{% endif %}

{% if deployment_type == 'online' %}
devices: ['/var'] # Workaround for https://bugs.launchpad.net/bugs/1455436

disable_root: 0
growpart:
  mode: auto
  devices: ['/var']
runcmd:
- xfs_growfs /var
{% endif %}