Skip to content

Commit 3de486e

Browse files
committed
OpenStack: create dualstack Ports for the Servers in UPI
This commit adds tasks to create the Servers Ports with the dualstack network and also include the addresses of the API and ingress dualstack Ports to the allowed address pairs.
1 parent c670cd9 commit 3de486e

File tree

3 files changed

+42
-0
lines changed

3 files changed

+42
-0
lines changed

upi/openstack/bootstrap.yaml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,18 @@
1919
- "{{ os_sg_master }}"
2020
allowed_address_pairs:
2121
- ip_address: "{{ os_apiVIP }}"
22+
when: os_subnet6_range is not defined
23+
24+
- name: 'Create the bootstrap dualstack server port'
25+
os_port:
26+
name: "{{ os_port_bootstrap }}"
27+
network: "{{ os_network }}"
28+
security_groups:
29+
- "{{ os_sg_master }}"
30+
allowed_address_pairs:
31+
- ip_address: "{{ os_apiVIP }}"
32+
- ip_address: "{{ os_apiVIP6 }}"
33+
when: os_subnet6_range is defined
2234

2335
- name: 'Set bootstrap port tag'
2436
command:

upi/openstack/compute-nodes.yaml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,20 @@
2121
- ip_address: "{{ os_ingressVIP }}"
2222
with_indexed_items: "{{ [os_port_worker] * os_compute_nodes_number }}"
2323
register: ports
24+
when: os_subnet6_range is not defined
25+
26+
- name: 'Create the dualstack Compute ports'
27+
openstack.cloud.port:
28+
name: "{{ item.1 }}-{{ item.0 }}"
29+
network: "{{ os_network }}"
30+
security_groups:
31+
- "{{ os_sg_worker }}"
32+
allowed_address_pairs:
33+
- ip_address: "{{ os_ingressVIP }}"
34+
- ip_address: "{{ os_ingressVIP6 }}"
35+
with_indexed_items: "{{ [os_port_worker] * os_compute_nodes_number }}"
36+
register: ports
37+
when: os_subnet6_range is defined
2438

2539
- name: 'Set Compute ports tag'
2640
ansible.builtin.command:

upi/openstack/control-plane.yaml

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,22 @@
2222
- ip_address: "{{ os_ingressVIP }}"
2323
with_indexed_items: "{{ [os_port_master] * os_cp_nodes_number }}"
2424
register: ports
25+
when: os_subnet6_range is not defined
26+
27+
- name: 'Create the dualstack Control Plane ports'
28+
openstack.cloud.port:
29+
name: "{{ item.1 }}-{{ item.0 }}"
30+
network: "{{ os_network }}"
31+
security_groups:
32+
- "{{ os_sg_master }}"
33+
allowed_address_pairs:
34+
- ip_address: "{{ os_apiVIP }}"
35+
- ip_address: "{{ os_apiVIP6 }}"
36+
- ip_address: "{{ os_ingressVIP }}"
37+
- ip_address: "{{ os_ingressVIP6 }}"
38+
with_indexed_items: "{{ [os_port_master] * os_cp_nodes_number }}"
39+
register: ports
40+
when: os_subnet6_range is defined
2541

2642
- name: 'Set Control Plane ports tag'
2743
ansible.builtin.command:

0 commit comments

Comments
 (0)