Disable firewalld in Bifrost container

Not needed inside the container, as firewalld runs on the host.
It was failing bifrost deploy jobs on Rocky.

Make directory creation idempotent during bootstrap.

Fix Bifrost tests by using python-ironicclient instead of python-openstackclient, which is not installed in the container.

Change-Id: I5b85efe655978214ad02abf3cda4c4d2b9649add
This commit is contained in:
Grzegorz Koper 2025-03-25 18:47:39 +01:00
parent 6ebdbb9795
commit 664a79f42f
3 changed files with 8 additions and 5 deletions

View File

@ -27,7 +27,7 @@
become: true
command: >
{{ kolla_container_engine }} exec bifrost_deploy
bash -c 'mkdir /root/.ssh ; mkdir /home/ironic/.ssh;
bash -c 'mkdir -p /root/.ssh ; mkdir -p /home/ironic/.ssh;
cp -f /etc/bifrost/id_rsa /root/.ssh/id_rsa &&
cp -f /etc/bifrost/id_rsa.pub /root/.ssh/id_rsa.pub &&
cp -f /etc/bifrost/ssh_config /root/.ssh/config &&

View File

@ -36,3 +36,6 @@ tls_root: "/etc/bifrost-certs"
# Whether to enable the legacy ironic-inspector service.
enable_inspector: "{{ bifrost_enable_ironic_inspector }}"
# Disable firewalld
use_firewalld: false

View File

@ -14,7 +14,7 @@ function test_bifrost {
# TODO(mgoddard): Use openstackclient when clouds.yaml works. See
# https://bugs.launchpad.net/bifrost/+bug/1754070.
attempts=0
while [[ $(sudo ${container_engine} exec bifrost_deploy bash -c "OS_CLOUD=bifrost openstack baremetal driver list -f value" | wc -l) -eq 0 ]]; do
while [[ $(sudo ${container_engine} exec bifrost_deploy bash -c "OS_CLOUD=bifrost baremetal driver list -f value" | wc -l) -eq 0 ]]; do
attempts=$((attempts + 1))
if [[ $attempts -gt 6 ]]; then
echo "Timed out waiting for ironic conductor to become active"
@ -22,9 +22,9 @@ function test_bifrost {
fi
sleep 10
done
sudo $container_engine exec bifrost_deploy bash -c "OS_CLOUD=bifrost openstack baremetal node list"
sudo $container_engine exec bifrost_deploy bash -c "OS_CLOUD=bifrost openstack baremetal node create --driver ipmi --name test-node"
sudo $container_engine exec bifrost_deploy bash -c "OS_CLOUD=bifrost openstack baremetal node delete test-node"
sudo $container_engine exec bifrost_deploy bash -c "OS_CLOUD=bifrost baremetal node list"
sudo $container_engine exec bifrost_deploy bash -c "OS_CLOUD=bifrost baremetal node create --driver redfish --name test-node"
sudo $container_engine exec bifrost_deploy bash -c "OS_CLOUD=bifrost baremetal node delete test-node"
}