user_data.j2 631 B

12345678910111213141516171819202122
  1. #cloud-config
  2. {% if type in ['node', 'master'] and 'docker' in volume_defs[type] %}
  3. mounts:
  4. - [ xvdb ]
  5. - [ ephemeral0 ]
  6. {% endif %}
  7. write_files:
  8. {% if type in ['node', 'master'] and 'docker' in volume_defs[type] %}
  9. - content: |
  10. DEVS=/dev/xvdb
  11. VG=docker_vg
  12. path: /etc/sysconfig/docker-storage-setup
  13. owner: root:root
  14. permissions: '0644'
  15. {% endif %}
  16. {% if deployment_vars[deployment_type].become | bool %}
  17. - path: /etc/sudoers.d/99-{{ deployment_vars[deployment_type].ssh_user }}-cloud-init-requiretty
  18. permissions: 440
  19. content: |
  20. Defaults:{{ deployment_vars[deployment_type].ssh_user }} !requiretty
  21. {% endif %}