This repository has been archived by the owner on May 31, 2022. It is now read-only.
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Use source images * Need to specify bash for &> syntax Issues worked around: * Manually configuring bridge via ip commands makes ifup fail to bring up the link. Adds a kayobe-network-bootstrap Zuul CI role that adds persistent configuration for the all-in-one network. * bridge not active after interfaces role bounce. Added a pause, similar to michaelrigart/ansible-role-interfaces#31 * fails installing docker python module for kolla user. WARNING: The repository located at mirror-int.ord.rax.opendev.org is not a trusted or secure host and is being ignored ERROR: No matching distribution found for docker===4.4.0 Adding trusted host for PyPI mirror. * Tenks fails to create block devices - missing qemu-img (in qemu-utils) * Tenks qemu emulator is different on Ubuntu Remaining issues: * Bare metal testing is unreliable on Ubuntu - some jobs see IPMI failures such as the following: ipmitool chassis bootdev pxe Error setting Chassis Boot Parameter 5\nError setting Chassis Boot Parameter 0\n Bare metal testing is disabled on Ubuntu for now. Depends-On: https://review.opendev.org/766984 Depends-On: https://review.opendev.org/766958 Story: 2004960 Task: 29393 Change-Id: I1985efae7c18f55c3ff7c27c17d6242523904f3e
- Loading branch information
1 parent
1ebadae
commit dd80f75
Showing
18 changed files
with
184 additions
and
104 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
# Kayobe network bootstrap | ||
|
||
Ansible role to bootstrap network configuration in CI. | ||
|
||
The role creates a bridge interface and a dummy interface, and adds the dummy | ||
interface as a port in the bridge. The bridge is assigned an IP address. | ||
|
||
## Role variables | ||
|
||
* `bridge_interface`: name of the bridge interface | ||
* `bridge_ip`: IP address to assign to the bridge | ||
* `bridge_prefix`: CIDR prefix to assign to the bridge | ||
* `bridge_port_interface`: name of the bridge port dummy interface |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
bridge_interface: | ||
bridge_ip: | ||
bridge_prefix: | ||
bridge_port_interface: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
--- | ||
- name: Ensure interfaces.d directory exists | ||
file: | ||
path: /etc/network/interfaces.d | ||
state: directory | ||
become: true | ||
|
||
- name: Ensure interfaces.d directory is sourced | ||
lineinfile: | ||
path: /etc/network/interfaces | ||
line: source /etc/network/interfaces.d/* | ||
become: true | ||
|
||
- name: Ensure all-in-one network dummy interface exists | ||
become: true | ||
copy: | ||
content: | | ||
auto {{ bridge_port_interface }} | ||
iface {{ bridge_port_interface }} inet manual | ||
dest: /etc/network/interfaces.d/ifcfg-{{ bridge_port_interface }} | ||
|
||
- name: Ensure all-in-one network bridge interface exists | ||
become: true | ||
copy: | ||
content: | | ||
auto {{ bridge_interface }} | ||
iface {{ bridge_interface }} inet static | ||
address {{ bridge_ip }} | ||
netmask {{ (bridge_ip ~ '/' ~ bridge_prefix) | ipaddr('netmask') }} | ||
bridge_ports {{ bridge_port_interface }} | ||
dest: /etc/network/interfaces.d/ifcfg-{{ bridge_interface }} | ||
|
||
- name: Ensure all-in-one network bridge interfaces are up | ||
become: true | ||
command: "{{ item }}" | ||
with_items: | ||
- "ifup {{ bridge_interface }}" | ||
- "ifup {{ bridge_port_interface }}" |
Oops, something went wrong.