Skip to content

Commit

Permalink
Merge pull request #18 from stackhpc/upstream/2024.1-2024-11-25
Browse files Browse the repository at this point in the history
Synchronise 2024.1 with upstream
  • Loading branch information
priteau authored Nov 25, 2024
2 parents b88d677 + d8cb5dc commit f35c746
Show file tree
Hide file tree
Showing 7 changed files with 22 additions and 55 deletions.
4 changes: 4 additions & 0 deletions elements/amphora-agent/package-installs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,10 @@ git-man:
uninstall: True
perl:
uninstall: True
# diskimage-builder installs firewalld in rockylinux, it's not needed as it
# blocks management and tenant traffic by default and we use security groups
firewalld:
uninstall: True

libffi-dev:
build-only: True
Expand Down
1 change: 0 additions & 1 deletion elements/amphora-agent/pkg-map
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@
},
"rocky": {
"9": {
"curl": "curl-minimal",
"isc-dhcp-client": "dhcp-client",
"python3-dev": "platform-python-devel",
"python3-venv": "",
Expand Down
5 changes: 3 additions & 2 deletions octavia/network/drivers/neutron/allowed_address_pairs.py
Original file line number Diff line number Diff line change
Expand Up @@ -194,12 +194,13 @@ def _update_security_group_rules(self, load_balancer, sec_grp_id):
# Don't remove egress rules and don't confuse other protocols with
# None ports with the egress rules. VRRP uses protocol 51 and 112
if (rule.get('direction') == 'egress' or
rule.get('protocol').upper() not in
rule.get('protocol') is None or
rule['protocol'].upper() not in
[constants.PROTOCOL_TCP, constants.PROTOCOL_UDP,
lib_consts.PROTOCOL_SCTP]):
continue
old_ports.append((rule.get('port_range_max'),
rule.get('protocol').lower(),
rule['protocol'].lower(),
rule.get('remote_ip_prefix')))

add_ports = set(updated_ports) - set(old_ports)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1071,7 +1071,8 @@ def test_update_vip(self):
fake_rules = [
{'id': 'rule-80', 'port_range_max': 80, 'protocol': 'tcp',
'remote_ip_prefix': '10.0.101.0/24'},
{'id': 'rule-22', 'port_range_max': 22, 'protocol': 'tcp'}
{'id': 'rule-22', 'port_range_max': 22, 'protocol': 'tcp'},
{'id': 'rule-None', 'port_range_max': 22},
]
list_rules = self.driver.network_proxy.security_group_rules
list_rules.return_value = fake_rules
Expand Down
52 changes: 7 additions & 45 deletions playbooks/image-build/run.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,51 +8,6 @@
become: yes
when:
- ansible_os_family == 'RedHat'
- name: Install apt packages
apt:
pkg: "{{ item }}"
state: "latest"
update_cache: yes
register: install_packages
become: yes
until: install_packages is success
retries: 5
delay: 2
with_items:
- qemu-utils
- uuid-runtime
- curl
- kpartx
- python3-yaml
- debootstrap
- qemu
- bc
- python3-venv
- python3-setuptools
when:
- ansible_os_family == 'Debian'
- name: Install rpm packages
dnf:
pkg: "{{ item }}"
state: "latest"
update_cache: yes
register: install_packages
become: yes
until: install_packages is success
retries: 5
delay: 2
with_items:
- qemu-img
- uuid
- curl
- kpartx
- python3-pyyaml
- qemu-kvm
- python3-setuptools
- yum
- podman
when:
- ansible_os_family == 'RedHat'
- name: Install required pip packages
pip:
name: "{{ item }}"
Expand All @@ -65,7 +20,14 @@
delay: 2
become: yes
with_items:
- bindep
- diskimage-builder
- setuptools
- name: Install binary dependencies from diskimage-builder
include_role:
name: bindep
vars:
bindep_dir: "{{ ansible_user_dir }}/{{ zuul.projects['opendev.org/openstack/diskimage-builder'].src_dir }}"
- name: Ensure artifacts/images directory exists
file:
path: '{{ ansible_user_dir }}/test-images'
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
fixes:
- |
Fixed potential AttributeError during listener update when security group
rule had no protocol defined (ie. it was null).
7 changes: 1 addition & 6 deletions zuul.d/jobs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -172,6 +172,7 @@
not Git master. This job does not publish the image.
run: playbooks/image-build/run.yaml
required-projects:
- openstack/diskimage-builder
- openstack/octavia
- openstack/octavia-lib
vars:
Expand All @@ -184,8 +185,6 @@
description: |
Builds an Ubuntu Jammy amphora image using diskimage-builder from Git
master. This job does not publish the image.
required-projects:
- openstack/diskimage-builder
vars:
amphora_os: ubuntu
amphora_os_release: jammy
Expand All @@ -197,8 +196,6 @@
description: |
Builds a CentOS 9 Stream amphora image using diskimage-builder from Git
master. This job does not publish the image.
required-projects:
- openstack/diskimage-builder
vars:
amphora_os: centos
amphora_os_release: 9-stream
Expand All @@ -210,8 +207,6 @@
description: |
Builds a Rocky Linux 9 amphora image using diskimage-builder from Git
master. This job does not publish the image.
required-projects:
- openstack/diskimage-builder
vars:
amphora_os: rocky
amphora_os_release: 9
Expand Down

0 comments on commit f35c746

Please sign in to comment.