Flatten Ansible role structure
[integration.git] / deployment / noheat / infra-openstack / ansible / roles / create_securitygroup / tasks / create_securitygroup.yml
1 ---
2 - name: "Create {{ secgrp.name }} security group"
3   os_security_group:
4     state: present
5     name: "{{ secgrp.name }}"
6
7 - name: "Create {{ secgrp.name }} security group rule for ping"
8   os_security_group_rule:
9     security_group: "{{ secgrp.name }}"
10     protocol: icmp
11     remote_ip_prefix: "{{ item }}"
12   loop: "{{ secgrp.remote_ip_prefix }}"
13
14 - name: "Create {{ secgrp.name }} security group rule for SSH"
15   os_security_group_rule:
16     security_group: "{{ secgrp.name }}"
17     protocol: tcp
18     port_range_min: 22
19     port_range_max: 22
20     remote_ip_prefix: "{{ item }}"
21   loop: "{{ secgrp.remote_ip_prefix }}"