From a65535edc7062edfba2f85ecf0736a27764c4983 Mon Sep 17 00:00:00 2001 From: Luis Tomas Bolivar Date: Tue, 25 Jan 2022 17:51:55 +0100 Subject: [PATCH] ovn-bgp-agent image support This adds support for the ovn-bgp-agent container image. ovn-bgp-agent can be found at https://opendev.org/x/ovn-bgp-agent. Change-Id: Ic656117becd9a059b56a4753a5c579c2ee703cc5 --- .../tcib/base/ovn-bgp-agent/ovn_bgp_agent.yaml | 8 ++++++++ container-images/tripleo_containers.yaml | 2 ++ container-images/tripleo_containers.yaml.j2 | 7 +++++++ healthcheck/ovn-bgp-agent | 12 ++++++++++++ 4 files changed, 29 insertions(+) create mode 100644 container-images/tcib/base/ovn-bgp-agent/ovn_bgp_agent.yaml create mode 100755 healthcheck/ovn-bgp-agent diff --git a/container-images/tcib/base/ovn-bgp-agent/ovn_bgp_agent.yaml b/container-images/tcib/base/ovn-bgp-agent/ovn_bgp_agent.yaml new file mode 100644 index 000000000..792748bac --- /dev/null +++ b/container-images/tcib/base/ovn-bgp-agent/ovn_bgp_agent.yaml @@ -0,0 +1,8 @@ +tcib_actions: +- run: bash /usr/local/bin/uid_gid_manage neutron +- run: dnf install -y {{ tcib_packages['common'] | join(' ') }} && dnf clean all && rm -rf /var/cache/dnf +- run: ln -s /usr/share/openstack-tripleo-common/healthcheck/ovn-bgp-agent /openstack/healthcheck && chmod a+rx /openstack/healthcheck +tcib_packages: + common: + - ovn-bgp-agent +tcib_user: neutron diff --git a/container-images/tripleo_containers.yaml b/container-images/tripleo_containers.yaml index a76642f08..6736040ea 100644 --- a/container-images/tripleo_containers.yaml +++ b/container-images/tripleo_containers.yaml @@ -53,6 +53,8 @@ container_images: image_source: tripleo - imagename: quay.io/tripleomaster/openstack-frr:current-tripleo image_source: tripleo +- imagename: quay.io/tripleomaster/openstack-ovn-bgp-agent:current-tripleo + image_source: tripleo - imagename: quay.io/tripleomaster/openstack-glance-api:current-tripleo image_source: tripleo - imagename: quay.io/tripleomaster/openstack-gnocchi-api:current-tripleo diff --git a/container-images/tripleo_containers.yaml.j2 b/container-images/tripleo_containers.yaml.j2 index 02c3c25ac..7c7384999 100644 --- a/container-images/tripleo_containers.yaml.j2 +++ b/container-images/tripleo_containers.yaml.j2 @@ -240,6 +240,13 @@ container_images_template: services: - OS::TripleO::Services::Frr +- imagename: "{{namespace}}/{{name_prefix}}ovn-bgp-agent{{name_suffix}}:{{tag}}" + image_source: tripleo + params: + - ContainerOvnBgpAgentImage + services: + - OS::TripleO::Services::Frr + - imagename: "{{namespace}}/{{name_prefix}}glance-api{{name_suffix}}:{{tag}}" image_source: tripleo params: diff --git a/healthcheck/ovn-bgp-agent b/healthcheck/ovn-bgp-agent new file mode 100755 index 000000000..f4c8b7c42 --- /dev/null +++ b/healthcheck/ovn-bgp-agent @@ -0,0 +1,12 @@ +#!/bin/bash + +. ${HEALTHCHECK_SCRIPTS:-/usr/share/openstack-tripleo-common/healthcheck}/common.sh + +process='ovn-bgp-agent' + +if ps -e | grep $process; then + exit 0 +else + echo "There is no $process process running in the container" + exit 1 +fi