---

- block:
  - name: format EBS volume
    filesystem:
      fstype: "{{ ebs_volume_fs_type }}"
      dev: "{{ ebs_volume_dev }}"

  - name: create mount point
    file:
      path: "{{ ebs_volume_mount_point }}"
      mode: 0777
      state: directory

  - name: mount EBS volume
    mount:
      name: "{{ ebs_volume_mount_point }}"
      src: "{{ ebs_volume_dev }}"
      fstype: "{{ ebs_volume_fs_type }}"
      state: mounted

  become: yes


