Skip to content

Commit 294278b

Browse files
authored
Merge pull request #1363 from stackhpc/2023.1/fix-ci-aio-networking
fix!: manage the `physical` interface in `ci-aio`
2 parents 363c1c8 + 6682a6f commit 294278b

File tree

5 files changed

+19
-19
lines changed

5 files changed

+19
-19
lines changed

.github/workflows/stackhpc-all-in-one.yml

Lines changed: 5 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -214,22 +214,12 @@ jobs:
214214
- name: Write Terraform network config
215215
run: |
216216
cat << EOF > etc/kayobe/environments/$KAYOBE_ENVIRONMENT/tf-networks.yml
217-
218-
admin_oc_net_name: admin
219-
admin_cidr: "{{ access_cidr.value }}"
220-
admin_allocation_pool_start: 0.0.0.0
221-
admin_allocation_pool_end: 0.0.0.0
222-
admin_gateway: "{{ access_gw.value }}"
223-
admin_bootproto: dhcp
224-
admin_ips:
217+
admin_oc_net_name: ethernet
218+
ethernet_cidr: "{{ access_cidr.value }}"
219+
ethernet_allocation_pool_start: 0.0.0.0
220+
ethernet_allocation_pool_end: 0.0.0.0
221+
ethernet_ips:
225222
controller0: "{{ access_ip_v4.value }}"
226-
admin_zone: admin
227-
EOF
228-
229-
- name: Write Terraform network interface config
230-
run: |
231-
cat << EOF > etc/kayobe/environments/$KAYOBE_ENVIRONMENT/inventory/group_vars/controllers/tf-network-interfaces
232-
admin_interface: "{{ access_interface.value }}"
233223
EOF
234224
235225
- name: Write all-in-one scenario config

etc/kayobe/environments/ci-aio/automated-setup.sh

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -76,10 +76,6 @@ fi
7676
sudo ip l set dummy1 up
7777
sudo ip l set dummy1 master breth1
7878

79-
if type apt; then
80-
sudo cp /run/systemd/network/* /etc/systemd/network
81-
fi
82-
8379
export KAYOBE_VAULT_PASSWORD=$(cat $BASE_PATH/vault-pw)
8480
pushd $BASE_PATH/src/kayobe-config
8581
source kayobe-env --environment ci-aio

etc/kayobe/environments/ci-aio/controllers.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,9 @@
66
# to setup the Kayobe user account. Default is {{ os_distribution }}.
77
controller_bootstrap_user: "{{ os_distribution if os_distribution == 'ubuntu' else 'cloud-user' }}"
88

9+
controller_extra_network_interfaces:
10+
- ethernet
11+
912
# Controller lvm configuration. See intentory/group_vars/controllers/lvm.yml
1013
# for the exact configuration.
1114
controller_lvm_groups:

etc/kayobe/environments/ci-aio/inventory/group_vars/controllers/network-interfaces

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,11 @@
22
###############################################################################
33
# Network interface definitions for the controller group.
44

5+
# Ethernet interface is the `primary` or `physical` interface associated
6+
# with the instance that the AIO deployment runs inside of. It is the interface used
7+
# to reach the instance.
8+
ethernet_interface: "{{ ansible_facts['default_ipv4']['interface'] }}"
9+
510
# Controller interface on all-in-one network.
611
aio_interface: breth1
712
# Use dummy1 if it exists, otherwise the bridge will have no ports.

etc/kayobe/environments/ci-aio/networks.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,12 @@ cleaning_net_name: aio
8080
###############################################################################
8181
# Network definitions.
8282

83+
# This network is required to be defined within `ci-aio` environment to ensure that
84+
# the network interface files are created appropriately and to provide easy inclusion
85+
# within the firewall configuration.
86+
ethernet_bootproto: dhcp
87+
ethernet_zone: trusted
88+
8389
# All-in-one network.
8490
aio_cidr: 192.168.33.0/24
8591
aio_allocation_pool_start: 192.168.33.3

0 commit comments

Comments
 (0)